Skip to main content

Report

Struct Report 

Source
pub struct Report {
Show 15 fields pub period_label: String, pub now_ms: i64, pub since_ms: i64, pub period_end_ms: Option<i64>, pub month_inferred: bool, pub account: Option<Usage>, pub account_error: Option<String>, pub tier: String, pub profile: Option<String>, pub offset_secs: i64, pub five_hour: Totals, pub weekly: Totals, pub month: Totals, pub daily: Option<Totals>, pub models: Vec<ModelUsage>,
}

Fields§

§period_label: String§now_ms: i64§since_ms: i64§period_end_ms: Option<i64>§month_inferred: bool§account: Option<Usage>

The control plane’s meters, when arkcli answered.

§account_error: Option<String>

Why the meters are absent, when that is worth saying (--no-api is a deliberate choice, not a fault).

§tier: String

The tier the figures are measured against (explicit --plan, else the profile’s own plan_tier, else the catalogue default).

§profile: Option<String>

arkcli profile the meters came from, for the header.

§offset_secs: i64

The server offset the account’s windows are cut in (seconds east of UTC). Period bounds print in that offset, never in a guessed local zone.

§five_hour: Totals§weekly: Totals§month: Totals§daily: Option<Totals>

Present only when the endpoint returned a daily window (media workloads; a text-only plan exposes 5h/weekly/monthly).

§models: Vec<ModelUsage>

Sorted by month AFP, descending.

Implementations§

Source§

impl Report

Source

pub fn afp_per_request(&self) -> Option<f64>

AFP per request over the 5-hour window — the meter’s figure divided by this store’s request count. Fresh enough to be meaningful, and the number the capacity questions are built on.

Source

pub fn reconcile(&self) -> Option<f64>

Meter vs computed AFP over the 5-hour window, as a signed percentage of the meter. A few percent is normal (a request still in flight, another machine on the same key); a large gap means an unmodelled item (media or Harness) or traffic this store cannot see.

Source

pub fn burn_per_day(&self) -> Option<f64>

Burn implied by the 5h window, in AFP/day: what the cycle’s current pace would consume over a day. None before the block has any use.

Source

pub fn window_quota(&self, catalog: &Catalog, share: f64) -> Option<f64>

The plan’s own quota for a window: its monthly AFP times the catalogue’s share of it. ARK publishes both, so the local estimate can print the same pair the console does — medium’s 10,000 / 35,000 / 100,000 AFP are exactly what its meters reported on 2026-10-20.

Source

pub fn rolling_reset(&self, totals: &Totals, dur_secs: i64) -> Option<i64>

When a locally cut window turns over: its oldest in-window row plus the window’s length, the same derivation the Go side uses. None before the window has rows — now + length is not a reset the data supports.

Trait Implementations§

Source§

impl Clone for Report

Source§

fn clone(&self) -> Self

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 Report

Source§

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

Formats the value using the given formatter. Read more

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, 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> 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 = !

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

fn try_from(value: U) -> Result<T, !>

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.