-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Update job status and workflow node job status based on websocket events #7940
Update job status and workflow node job status based on websocket events #7940
Conversation
Build succeeded.
|
Note to self - remove this line:
|
summary_fields: { | ||
job: { | ||
name: 'Foo Job Template', | ||
elapsed: 9000, |
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.
elapsed: 9000, | |
elapsed: 9001, |
|
||
if ( | ||
['successful', 'failed', 'error', 'cancelled'].includes( | ||
lastMessage.status |
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.
Once a job finishes running, the job is refreshed via the API so that we can display all data that comes available after a job finishes.
I like the approach of adding the auto-reload to the hook in order to fetch the summary data when a final status event is received. 👍
The summary statistics may not be correct until the job details endpoint returns "event_processing_finished": true,
. Depending on the scale of the job, this can happen long after the final job status message is received.
To detect when event processing is actually finished, we might need to enter a retry loop and poll the api until the event_processing_finished
flag is true
or some reasonable retry limit is reached.
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.
LGTM. I would like to see a retry loop added for event_processing_finished
(see: https://github.com/ansible/awx/pull/7940/files#r474040690) but doesn't necessarily need to be in this PR.
@mabashian this bug is live on devel and this branch: #8076 |
237a9b0
to
679465d
Compare
Build failed.
|
Build succeeded.
|
@unlikelyzero verify that the Jobs List websocket events work alongside the workflow in two different windows. I'd like to make sure it all lines up. |
@mabashian we have a working test for this but need some sort of testability added to the sparkline elements. At the moment, there is no way to determine their state. |
…tch job after job finishes running to display all available info.
…lay all job info for relevant nodes.
…an determine whether or not a status has been updated via websockets.
5ebe4f0
to
8fab455
Compare
Build failed.
|
recheck |
Build failed.
|
recheck |
Build failed.
|
recheck |
Build succeeded.
|
tested via #5501 |
Build succeeded (gate pipeline).
|
SUMMARY
link #6616
link #7157
This PR does a couple of things:
ISSUE TYPE
COMPONENT NAME