#[repr(u8)]pub enum MetadataOp {
Stat = 0,
ReadLink = 1,
MkDir = 2,
RmDir = 3,
Unlink = 4,
HardLink = 5,
Symlink = 6,
Chmod = 7,
OpenCreate = 8,
}Expand description
Which metadata syscall is being measured.
Separate ops feed independent controllers because their service-time
distributions differ — stat (pure lookup) and unlink (mutation
plus parent-directory write) hit different code paths on the
metadata server and converge on very different baselines. Mixing
them in one controller pollutes the per-op latency signal: the
resulting ratio drifts with operation-mix changes that have nothing
to do with congestion (the long-window baseline percentile shifts
as the mix changes, and in cross mode the inter-quantile spread
becomes a function of the mix rather than the load).
The variants are ordered so they index a fixed-size array when paired
with a Side; see N_META_OPS.
Variants§
Stat = 0
stat / lstat / symlink_metadata. Also covers
canonicalize and read-only File::open — both are dominated
by lookup work on the metadata path.
ReadLink = 1
readlink. Distinct from Stat because it pulls the symlink’s
target body, not just the inode header.
MkDir = 2
mkdir / create_dir. Allocates a directory inode and wires
it into the parent.
RmDir = 3
rmdir / remove_dir. Verifies emptiness then removes the dir.
Unlink = 4
unlink / remove_file. Decrements link count, frees inode at
zero.
HardLink = 5
link / hard_link. Bumps an existing inode’s link count.
Symlink = 6
symlink (creation). Allocates an inode whose body is the
target path.
Chmod = 7
Permission / ownership / timestamp updates: chmod /
set_permissions, chown / fchownat, utimes / utimensat.
Bucketed together because they’re all single inode writes.
OpenCreate = 8
open(O_CREAT) / File::create. Allocates a regular-file
inode and wires it into the parent.
Implementations§
Source§impl MetadataOp
impl MetadataOp
Sourcepub const ALL: [MetadataOp; 9]
pub const ALL: [MetadataOp; 9]
All op variants, in discriminant order. Useful when wiring up a controller for every op kind without having to spell out each.
Trait Implementations§
Source§impl Clone for MetadataOp
impl Clone for MetadataOp
Source§fn clone(&self) -> MetadataOp
fn clone(&self) -> MetadataOp
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for MetadataOp
impl Debug for MetadataOp
Source§impl Hash for MetadataOp
impl Hash for MetadataOp
Source§impl PartialEq for MetadataOp
impl PartialEq for MetadataOp
Source§fn eq(&self, other: &MetadataOp) -> bool
fn eq(&self, other: &MetadataOp) -> bool
self and other values to be equal, and is used by ==.impl Copy for MetadataOp
impl Eq for MetadataOp
impl StructuralPartialEq for MetadataOp
Auto Trait Implementations§
impl Freeze for MetadataOp
impl RefUnwindSafe for MetadataOp
impl Send for MetadataOp
impl Sync for MetadataOp
impl Unpin for MetadataOp
impl UnsafeUnpin for MetadataOp
impl UnwindSafe for MetadataOp
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request