pub struct QueryOptions {Show 13 fields
pub region: String,
pub allow_stale: bool,
pub auth_token: String,
pub wait_index: u64,
pub prefix: String,
pub next_token: String,
pub namespace: String,
pub filter: String,
pub reverse: bool,
pub wait_time: TimeDelta,
pub params: HashMap<String, String>,
pub headers: HashMap<String, String>,
pub per_page: i32,
}
Expand description
QueryOptions are used to parametrize a query
This struct was generated based on the Go types of the official Nomad API client.
Fields§
§region: String
Providing a datacenter overwrites the region provided by the Config
allow_stale: bool
AllowStale allows any Nomad server (non-leader) to service a read. This allows for lower latency and higher throughput
auth_token: String
AuthToken is the secret ID of an ACL token
wait_index: u64
WaitIndex is used to enable a blocking query. Waits until the timeout or the next index is reached
prefix: String
If set, used as prefix for resource list searches
next_token: String
NextToken is the token used to indicate where to start paging for queries that support paginated lists. This token should be the ID of the next object after the last one seen in the previous response.
namespace: String
Namespace is the target namespace for the query.
filter: String
Filter specifies the go-bexpr filter expression to be used for filtering the data prior to returning a response
reverse: bool
Reverse is used to reverse the default order of list results.
Currently only supported by specific endpoints.
wait_time: TimeDelta
WaitTime is used to bound the duration of a wait. Defaults to that of the Config, but can be overridden.
params: HashMap<String, String>
Set HTTP parameters on the query.
headers: HashMap<String, String>
Set HTTP headers on the query.
per_page: i32
PerPage is the number of entries to be returned in queries that support paginated lists.
Trait Implementations§
Source§impl Clone for QueryOptions
impl Clone for QueryOptions
Source§fn clone(&self) -> QueryOptions
fn clone(&self) -> QueryOptions
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more