-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
fix: Mutex not being released on step completion #4847
Conversation
I feel like we're playing whack-a-mole with these bugs. Just another push to see if there is a more general way we could periodically check semaphore are consistent? |
This fix requires cleaning up the template level lock release. |
@@ -1691,6 +1691,9 @@ func (woc *wfOperationCtx) executeTemplate(nodeName string, orgTmpl wfv1.Templat | |||
woc.computeMetrics(processedTmpl.Metrics.Prometheus, localScope, realTimeScope, false) | |||
} | |||
} | |||
if processedTmpl.Synchronization != nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Node status will be calculated here for retry nodes. The lock has to be released if the node is fulfilled
@@ -155,6 +155,7 @@ func (cm *Manager) Release(wf *wfv1.Workflow, nodeName string, syncRef *wfv1.Syn | |||
|
|||
if syncLockHolder, ok := cm.syncLockMap[lockName.EncodeName()]; ok { | |||
syncLockHolder.release(holderKey) | |||
syncLockHolder.removeFromQueue(holderKey) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is mainly for edge cases to avoid the release node shouldn't be in pending state.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rubber-stamp
@@ -37,3 +37,5 @@ git-ask-pass.sh | |||
/go-diagrams/ | |||
/.run/ | |||
pprof | |||
pkg/apiclient/sensor/sensor.swagger.json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
duplicate lines
This fix is out on https://github.com/argoproj/argo/releases/tag/v2.12.5 |
Checklist:
Fixes #4832
Fixes #4870