Categorygithub.com/ondat/metrics-exporter
modulepackage
0.1.7
Repository: https://github.com/ondat/metrics-exporter.git
Documentation: pkg.go.dev

# README

Metrics exporter

PVC metrics exporter designed to run alongside an Ondat instance.

It knows how to extract the relevant information about Ondat volumes and makes it available as a Prometheus scraping endpoint.

Disks not owned by Ondat are ignored.

preview-overview-architecture

References

# Packages

No description provided by the author

# Functions

ExtractOndatVolumesNumbers parses the output from "ls -l" on the storageos block devices directory further building the list of volume with Major & Minor numbers.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ProcDiskstats reads the diskstats file and returns an array of Diskstats (one per line/device).

# Constants

DISK_SUBSYSTEM defines the common category shared between all metrics we expose about PVCs "ondat_disk_...".
No description provided by the author
No description provided by the author
No description provided by the author
FILE_SYSTEM_SUBSYSTEM defines the common category shared between all filesystem metrics "ondat_filesystem_...".
ONDAT_NAMESPACE defines the common namespace used by all our metrics.
PROC_DISKSTATS_MIN_NUM_FIELDS is the minimum number of fields we expect to find in the /proc/diskstats (kernels v4.18+ add more).
SCRAPE_SUBSYSTEM defines the category about the metrics gathering process itself (success, failures, duration, etc) "ondat_scrape_...".
SECOND_IN_MILLISECONDS defines the number of seconds on a milliseconds.
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
DiskStatsCollector implements the prometheus Collector interface Its sole responsibility is gathering metrics on PVCs.
No description provided by the author
No description provided by the author
No description provided by the author
Metric is a wrapper over prometheus types (desc and type) defining a standalone metric.
No description provided by the author

# Interfaces

No description provided by the author