nomad
nomad copied to clipboard
cli: support pagination on requests within `nomad operator debug`
The nomad operator debug
command collects data from a number of Nomad API endpoints and writes this data out to a file on the filesystem where the command is being run. These API calls do not utilise pagination, an API feature that was added after the release of this command which, in large Nomad clusters, can result in additional load on both the machine responding to the request, and the machine where the command is being run from.
The command could optionally support pagination on all API endpoints that support it. This would allow data to be collected in sensible increments. It is worth noting this method would increase execution time of the command and involve a large number of overall API requests. This should be included in documentation so cluster operators can run the command in the correct way for their cluster.
cc @davemay99
See also https://github.com/hashicorp/nomad/issues/15565