-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Service Registration and Health Checks flapping when task name starts with another task name #2294
Comments
Also switched from a build tag to an env var for enabling these tests so at least we know if they stop building properly without enabling them.
Pushed a branch with new test reproducing the bug you reported. I'm working on a significant refactor of our consul interaction code that will fix this, but it looks like that refactoring won't be done in time for 0.5.5 I'll try to get a patch in. |
Thanks for quick reply! We've used a quick and obvious workaround of changing the task name for now (so we're not in a hurry here). :) But would be nice to have that fixed so looking forward to your refactoring. Would you mind mention/ping me once you going to merge those changes? Thanks |
@ashald I'll definitely close this ticket when the fix lands whether it's in a patch or as part of the larger refactoring! |
Thanks! |
Fixes #2478 #2474 #1995 #2294 The new client only handles agent and task service advertisement. Server discovery is mostly unchanged. The Nomad client agent now handles all Consul operations instead of the executor handling task related operations. When upgrading from an earlier version of Nomad existing executors will be told to deregister from Consul so that the Nomad agent can re-register the task's services and checks. Drivers - other than qemu - now support an Exec method for executing abritrary commands in a task's environment. This is used to implement script checks. Interfaces are used extensively to avoid interacting with Consul in tests that don't assert any Consul related behavior.
Fixes #2478 #2474 #1995 #2294 The new client only handles agent and task service advertisement. Server discovery is mostly unchanged. The Nomad client agent now handles all Consul operations instead of the executor handling task related operations. When upgrading from an earlier version of Nomad existing executors will be told to deregister from Consul so that the Nomad agent can re-register the task's services and checks. Drivers - other than qemu - now support an Exec method for executing abritrary commands in a task's environment. This is used to implement script checks. Interfaces are used extensively to avoid interacting with Consul in tests that don't assert any Consul related behavior.
Fixes #2478 #2474 #1995 #2294 The new client only handles agent and task service advertisement. Server discovery is mostly unchanged. The Nomad client agent now handles all Consul operations instead of the executor handling task related operations. When upgrading from an earlier version of Nomad existing executors will be told to deregister from Consul so that the Nomad agent can re-register the task's services and checks. Drivers - other than qemu - now support an Exec method for executing abritrary commands in a task's environment. This is used to implement script checks. Interfaces are used extensively to avoid interacting with Consul in tests that don't assert any Consul related behavior.
Fixed on master by #2467 |
I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues. |
If filing a bug please include the following:
Nomad version
Nomad v0.5.0
Operating system and Environment details
CentOS 7
Issue
When job created as described in
Reproduction steps
, the task "that starts with other task's name" if "flaky" in Consul. it's service definition being "registered"/"deregistered" every few seconds and health-checks failing to execute (we tried script and HTTP checks).Reproduction steps
Create a job with a group and 2 tasks called
foo
andfoobar
.Nomad Client logs (if appropriate)
Executor log
The text was updated successfully, but these errors were encountered: