You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
See above. Run any tasks in a tight loop. It is also relatively easy to test by restarting the plugin and observing that all of the goroutines are freed as a result.
The text was updated successfully, but these errors were encountered:
Hi @stswidwinski and thanks for raising this issue along with a PR. I see that Seth has assigned himself as reviewer on the PR, therefore I will assign this to him also to complete the loop.
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 you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
Nomad version
1.4.2
Operating system and Environment details
Unix
Issue
Nomad client leaks goroutines under normal operation, at least 1 goroutine per task. The exact reason why:
https://github.com/hashicorp/nomad/blob/main/plugins/drivers/client.go#L190
This context is never cancelled unless the parent contexts are cancelled or done.
https://github.com/hashicorp/nomad/blob/main/plugins/drivers/client.go#L32
The other one has the lifetime of... forever
https://github.com/hashicorp/nomad/blob/main/client/allocrunner/taskrunner/task_runner.go#L623
Because none of them are ever cancelled we leak goroutines. The goroutine leaked is started here:
https://github.com/LK4D4/joincontext/blob/master/context.go#L33
Reproduction steps
See above. Run any tasks in a tight loop. It is also relatively easy to test by restarting the plugin and observing that all of the goroutines are freed as a result.
The text was updated successfully, but these errors were encountered: