Struct collectd_plugin::ValueList[][src]

pub struct ValueList<'a> {
    pub values: Vec<ValueReport<'a>>,
    pub plugin: &'a str,
    pub plugin_instance: Option<&'a str>,
    pub type_: &'a str,
    pub type_instance: Option<&'a str>,
    pub host: &'a str,
    pub time: DateTime<Utc>,
    pub interval: Duration,
    pub meta: HashMap<String, MetaValue>,
    // some fields omitted
}
Expand description

Contains values and metadata that collectd has collected from plugins

Fields

values: Vec<ValueReport<'a>>plugin: &'a str

The plugin that submitted this value. This would be your PluginManager when submitting values

plugin_instance: Option<&'a str>

Distinguishes entities that yield metrics. Each core would be a different instance of the same plugin, as each core reports “idle”, “user”, “system” metrics.

type_: &'a str

This is the string found in types.db, determines how many values are expected and how they should be interpreted

type_instance: Option<&'a str>

The type instance is used to separate values of identical type which nonetheless belong to one another. For instance, even though “free”, “used”, and “total” all have types of “Memory” they are different type instances.

host: &'a str

The hostname where the values were collectd

time: DateTime<Utc>

The timestamp at which the value was collected

interval: Duration

The interval in which new values are to be expected

meta: HashMap<String, MetaValue>

Metadata associated to the reported values

Implementations

Collectd does not automatically convert Derived values into a rate. This is why many write plugins have a StoreRates config option so that these rates are calculated on demand from collectd’s internal cache. This function will return a vector that can supercede the values field that contains the rate of all non-gauge values. Values that are gauges remain unchanged, so one doesn’t need to resort back to values field as this function will return everything prepped for submission.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

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

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

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

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.