[][src]Struct cannyls::metrics::DeviceMetrics

pub struct DeviceMetrics { /* fields omitted */ }

Deviceのメトリクス.

Methods

impl DeviceMetrics
[src]

pub fn status(&self) -> DeviceStatus
[src]

デバイスの稼働状態.

Prometheus

# 0=stopped
# 1=starting
# 2=running
cannyls_device_status = 0|1|2

pub fn enqueued_commands(&self) -> &DeviceCommandCounter
[src]

デバイスのキューに挿入されたコマンドの数.

Prometheus

cannyls_device_enqueued_commands_total { command="put" } = <COUNTER>
cannyls_device_enqueued_commands_total { command="get" } = <COUNTER>
cannyls_device_enqueued_commands_total { command="head" } = <COUNTER>
cannyls_device_enqueued_commands_total { command="delete" } = <COUNTER>
cannyls_device_enqueued_commands_total { command="list" } = <COUNTER>
cannyls_device_enqueued_commands_total { command="stop" } = <COUNTER>

pub fn dequeued_commands(&self) -> &DeviceCommandCounter
[src]

デバイスのキューから取り出されたコマンドの数.

Prometheus

cannyls_device_dequeued_commands_total { command="put" } = <COUNTER>
cannyls_device_dequeued_commands_total { command="get" } = <COUNTER>
cannyls_device_dequeued_commands_total { command="head" } = <COUNTER>
cannyls_device_dequeued_commands_total { command="delete" } = <COUNTER>
cannyls_device_dequeued_commands_total { command="list" } = <COUNTER>
cannyls_device_dequeued_commands_total { command="stop" } = <COUNTER>

pub fn failed_commands(&self) -> &DeviceCommandCounter
[src]

実行に失敗したコマンドの数.

Prometheus

cannyls_device_failed_commands_total { command="put" } = <COUNTER>
cannyls_device_failed_commands_total { command="get" } = <COUNTER>
cannyls_device_failed_commands_total { command="head" } = <COUNTER>
cannyls_device_failed_commands_total { command="delete" } = <COUNTER>
cannyls_device_failed_commands_total { command="list" } = <COUNTER>
cannyls_device_failed_commands_total { command="stop" } = <COUNTER>

pub fn busy_commands(&self) -> &DeviceCommandCounter
[src]

デバイスが忙しくて実行を諦めたコマンドの数.

Prometheus

cannyls_device_busy_commands_total { command="put" } = <COUNTER>
cannyls_device_busy_commands_total { command="get" } = <COUNTER>
cannyls_device_busy_commands_total { command="head" } = <COUNTER>
cannyls_device_busy_commands_total { command="delete" } = <COUNTER>
cannyls_device_busy_commands_total { command="list" } = <COUNTER>
cannyls_device_busy_commands_total { command="stop" } = <COUNTER>

pub fn side_jobs(&self) -> u64
[src]

補助タスクの実行回数.

Prometheus

cannyls_device_side_jobs_total <COUNTER>

pub fn queue_len(&self) -> usize
[src]

デバイスキューの長さ(i.e., 実行待ちのコマンド数).

Prometheus

sum(cannyls_device_enqueued_commands_total - cannyls_device_dequeued_commands_total)

pub fn storage(&self) -> Option<&StorageMetrics>
[src]

ストレージのメトリクスを返す.

デバイスの状態がRunning以外の場合にはNoneが返る.

Trait Implementations

impl Clone for DeviceMetrics
[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for DeviceMetrics
[src]

Auto Trait Implementations

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

type Error = !

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

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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

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

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]