-
Notifications
You must be signed in to change notification settings - Fork 100
Support agent available rollback fields #5975
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
base: main
Are you sure you want to change the base?
Conversation
529235c to
68867ee
Compare
| rawComp []byte | ||
| seqno sqn.SeqNo | ||
| unhealthyReason *[]string | ||
| rawAvailableRollbacks []byte |
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.
not sure this was RFCed but could this be part of upgrade meta? like scheduled_at or error_msg so we don't pollute root object with upgrade specific stuff?
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.
i imagine you don't need this info outside of upgrade window anyways
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.
Not sure if you are referring to the checkin request body, the validatedCheckin struct or the ES document structure.
The main reason that I didn't mix this information with existing upgrade stuff is that there are assumptions about upgrade details and I didn't know if there are more around other other upgrade fields.
The information about available rollbacks must survive beyond the duration of a single upgrade (and fleet detects the conclusion of an upgrade by the upgrade_details field disappearing in the checkin body) and it's also not a stable intrinsic characteristic of agent so that it can go in something like local_metadata.
The RFC will be updated with the final schema we are gonna have in this PR.
What is the problem this PR solves?
This PR handles new
available_rollbacksfield sent by elastic-agent during checkin (implemented in PR elastic/elastic-agent#11143).This information will be consumed by the Fleet UI to allow a manual rollback of recently upgraded agents.
How does this PR solve the problem?
This PR introduces new
available_rollbacksfield both inCheckinRequestandpendingTstructs as a slice ofAvailableRollbacksand a JSON array of objects respectively.How to test this PR locally
Refer to PR elastic/elastic-agent#11143
How to test this PR locallysection.Design Checklist
Checklist
./changelog/fragmentsusing the changelog toolRelated issues