Skip to content
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

cli: -stale flag on operator debug command is never utilised #10767

Closed
jrasell opened this issue Jun 16, 2021 · 4 comments · Fixed by #11678
Closed

cli: -stale flag on operator debug command is never utilised #10767

jrasell opened this issue Jun 16, 2021 · 4 comments · Fixed by #11678
Assignees
Labels
stage/accepted Confirmed, and intend to work on. No timeline committment though. theme/cli type/bug
Milestone

Comments

@jrasell
Copy link
Member

jrasell commented Jun 16, 2021

Nomad version

main branch at e16a35167bf1430674e88658a6a31770b11ccbde

Issue

The nomad operator debug command includes a stale flag to allow toggling of the API query parameters, however, it is never used. The command should therefore be updated to take advantage of this flag and the behaviour it allows.

@jrasell jrasell added type/bug theme/cli stage/accepted Confirmed, and intend to work on. No timeline committment though. labels Jun 16, 2021
@tgross tgross self-assigned this Dec 14, 2021
@schmichael
Copy link
Member

debug should be stale by default if possible. Since we query each server it's rather silly not to use -stale because otherwise we end up always returning the leader's view of the world.

I think basically all of our APIs should be stale by default, but that ship has sailed.

@tgross
Copy link
Member

tgross commented Dec 14, 2021

Preliminary pass at this: it looks like many of the api.Agent package methods don't accept query parameters (which we'd need for the CLI to set the ?stale query parameter). Probably because most of those APIs don't need the stale parameter because they're talking directly to the agent. But it looks like some of those APIs may have grown features over time (and/or were secured with ACLs) that require talking to the server(s), and that's why this is all broke. I'll find the minimum set of api functions that we need to serve operator debug just so that we're not reworking the whole package to fix this.

@tgross
Copy link
Member

tgross commented Dec 14, 2021

I've opened #11678 with the bug fix.

@tgross tgross added this to the 1.2.4 milestone Dec 14, 2021
@github-actions
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 13, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
stage/accepted Confirmed, and intend to work on. No timeline committment though. theme/cli type/bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants