Skip to main content

CommonArgs

Struct CommonArgs 

Source
pub struct CommonArgs {
Show 24 fields pub progress: bool, pub progress_type: Option<ProgressType>, pub progress_delay: Option<String>, pub verbose: u8, pub ops_throttle: usize, pub iops_throttle: usize, pub max_workers: usize, pub max_blocking_threads: usize, pub auto_meta_throttle: bool, pub auto_meta_initial_cwnd: u32, pub auto_meta_min_cwnd: u32, pub auto_meta_max_cwnd: u32, pub auto_meta_alpha: f64, pub auto_meta_beta: f64, pub auto_meta_baseline_percentile: f64, pub auto_meta_current_percentile: f64, pub auto_meta_increase_step: u32, pub auto_meta_decrease_step: u32, pub auto_meta_long_window: Duration, pub auto_meta_short_window: Duration, pub auto_meta_tick_interval: Duration, pub auto_meta_histogram: bool, pub auto_meta_histogram_log: Option<PathBuf>, pub auto_meta_histogram_interval: Duration,
}

Fields§

§progress: bool

Show progress

§progress_type: Option<ProgressType>

Set the type of progress display

If specified, –progress flag is implied.

§progress_delay: Option<String>

Set delay between progress updates

Default is 200ms for interactive mode (ProgressBar) and 10s for non-interactive mode (TextUpdates). If specified, –progress flag is implied. Accepts human-readable durations like “200ms”, “10s”, “5min”.

§verbose: u8

Verbose level (implies “summary”): -v INFO / -vv DEBUG / -vvv TRACE (default: ERROR)

§ops_throttle: usize

Throttle the number of operations per second (0 = no throttle)

§iops_throttle: usize

Limit I/O operations per second (0 = no throttle)

Requires –chunk-size to calculate I/O operations per file: ((file_size - 1) / chunk_size) + 1

§max_workers: usize

Number of worker threads (0 = number of CPU cores)

§max_blocking_threads: usize

Number of blocking worker threads (0 = Tokio default of 512)

§auto_meta_throttle: bool

Enable adaptive metadata-ops throttling (latency-ratio controller)

§auto_meta_initial_cwnd: u32

Initial concurrency window for adaptive metadata throttle

§auto_meta_min_cwnd: u32

Minimum concurrency window (floor below which cwnd cannot shrink)

§auto_meta_max_cwnd: u32

Maximum concurrency window (ceiling on adaptive growth)

§auto_meta_alpha: f64

Latency ratio below which cwnd grows (current / baseline). Default 1.3, sized to sit just below the steady-state p10/p50 inter-quantile spread of typical metadata syscalls so the controller climbs only when the spread compresses. alpha may be set below 1.0 in passive matched mode (grow only when recent is meaningfully faster than baseline). The natural scale depends on the percentile pair: matched percentiles produce a steady- state ratio of 1.0; cross percentiles produce a ratio above 1.0 set by the inter-quantile spread of the latency distribution.

§auto_meta_beta: f64

Latency ratio above which cwnd shrinks. Default 1.8, sized to sit above the steady-state p10/p50 spread so only genuine queueing-driven tail growth triggers a backoff.

§auto_meta_baseline_percentile: f64

Percentile (in [0.0, 1.0)) applied to the long-horizon window to derive the baseline statistic. Default 0.1 (p10): paired with the p50 current percentile this gives a cross-percentile ratio whose steady-state level tracks the lower-half spread of the per-syscall latency distribution and rises with queueing. With matched percentiles (baseline == current) the steady-state ratio sits near 1.0 instead.

§auto_meta_current_percentile: f64

Percentile (in [0.0, 1.0)) applied to the short-horizon window to derive the current statistic. Default 0.5 (p50). Must be >= baseline percentile. See --auto-meta-baseline-percentile.

§auto_meta_increase_step: u32

How much to grow cwnd on each under-shoot tick

§auto_meta_decrease_step: u32

How much to shrink cwnd on each over-shoot tick

§auto_meta_long_window: Duration

Long-horizon sample window (e.g. “10s”). Drives the baseline percentile; samples older than this are evicted on every tick.

§auto_meta_short_window: Duration

Short-horizon sample window (e.g. “1s”). Drives the current-state percentile; must be strictly less than --auto-meta-long-window.

§auto_meta_tick_interval: Duration

Control-loop tick interval (e.g. “50ms”)

§auto_meta_histogram: bool

Enable in-memory HDR latency histograms per (side, op). Implies --auto-meta-throttle. Adds a distribution panel beneath the existing one-line-per-controller summary in the progress display.

§auto_meta_histogram_log: Option<PathBuf>

Write a binary log of per-(side, op) HDR histograms to the given path. The file is truncated if it already exists — rename or move logs you want to keep across runs. Format documented in docs/congestion_control.md. Implies --auto-meta-histogram and --auto-meta-throttle.

§auto_meta_histogram_interval: Duration

Snapshot cadence for the histogram logger (e.g. “1s”). Drives both the panel refresh rate and the log-file record interval. Range [100ms, 60s].

Implementations§

Source§

impl CommonArgs

Source

pub fn output_config(&self, quiet: bool, print_summary: bool) -> OutputConfig

Build a crate::OutputConfig. quiet and print_summary are supplied by the caller (each binary owns its own --quiet and --summary flags so it can document binary-specific semantics).

Source

pub fn runtime_config(&self) -> RuntimeConfig

Build a crate::RuntimeConfig from these args.

Source

pub fn throttle_config( &self, max_open_files: Option<usize>, chunk_size: u64, ) -> ThrottleConfig

Build a crate::ThrottleConfig. max_open_files and chunk_size are supplied by the caller (filegen has its own --max-open-files default; chunk_size has different parser types per binary).

Source

pub fn progress_requested(&self) -> bool

Returns true if any progress-related flag was set.

--auto-meta-histogram implies progress because its sole purpose is to render a live distribution panel. --auto-meta-histogram-log does NOT imply progress — it writes to a file regardless of progress mode, and forcing a display would be worse UX for users who only want the file.

Source

pub fn user_progress_settings( &self, kind: LocalProgressKind, ) -> Option<ProgressSettings>

Build user-facing crate::ProgressSettings when any progress flag was set, else None. kind selects the tool-specific printer. For rcp’s remote-master and rcpd’s remote progress modes, build ProgressSettings directly instead of using this helper.

Trait Implementations§

Source§

impl Args for CommonArgs

Source§

fn group_id() -> Option<Id>

Report the ArgGroup::id for this set of arguments
Source§

fn augment_args<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate Self via FromArgMatches::from_arg_matches_mut Read more
Source§

fn augment_args_for_update<'b>(__clap_app: Command) -> Command

Append to Command so it can instantiate self via FromArgMatches::update_from_arg_matches_mut Read more
Source§

impl Clone for CommonArgs

Source§

fn clone(&self) -> CommonArgs

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for CommonArgs

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl FromArgMatches for CommonArgs

Source§

fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>

Instantiate Self from ArgMatches, parsing the arguments as needed. Read more
Source§

fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.
Source§

fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>

Assign values from ArgMatches to self.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> FromRef<T> for T
where T: Clone,

Source§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoRequest<T> for T

Source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
Source§

impl<L> LayerExt<L> for L

Source§

fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>
where L: Layer<S>,

Applies the layer to a service and wraps it in Layered.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more