metrics

package
v0.3.52 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 24, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const MetricPrefix = "armada_"

Variables

This section is empty.

Functions

This section is empty.

Types

type FloatMetrics

type FloatMetrics struct {
	// contains filtered or unexported fields
}

func (*FloatMetrics) GetBuckets

func (d *FloatMetrics) GetBuckets() map[float64]uint64

func (*FloatMetrics) GetCount

func (d *FloatMetrics) GetCount() uint64

func (*FloatMetrics) GetMax

func (d *FloatMetrics) GetMax() float64

func (*FloatMetrics) GetMedian

func (d *FloatMetrics) GetMedian() float64

func (*FloatMetrics) GetMin

func (d *FloatMetrics) GetMin() float64

func (*FloatMetrics) GetSum

func (d *FloatMetrics) GetSum() float64

type FloatMetricsRecorder

type FloatMetricsRecorder struct {
	// contains filtered or unexported fields
}

func NewDefaultJobDurationMetricsRecorder

func NewDefaultJobDurationMetricsRecorder() *FloatMetricsRecorder

func NewFloatMetricsRecorder

func NewFloatMetricsRecorder(buckets ...float64) *FloatMetricsRecorder

func (*FloatMetricsRecorder) GetMetrics

func (d *FloatMetricsRecorder) GetMetrics() *FloatMetrics

func (*FloatMetricsRecorder) Record

func (d *FloatMetricsRecorder) Record(value float64)

type JobMetricsRecorder

type JobMetricsRecorder struct {
	// contains filtered or unexported fields
}

func NewJobMetricsRecorder

func NewJobMetricsRecorder() *JobMetricsRecorder

func (*JobMetricsRecorder) Metrics

func (r *JobMetricsRecorder) Metrics() []*QueueMetrics

func (*JobMetricsRecorder) RecordJobRuntime

func (r *JobMetricsRecorder) RecordJobRuntime(pool string, priorityClass string, jobRuntime time.Duration)

func (*JobMetricsRecorder) RecordResources

func (r *JobMetricsRecorder) RecordResources(pool string, priorityClass string, resources armadaresource.ComputeResourcesFloat)

type QueueInfoCollector

type QueueInfoCollector struct {
	// contains filtered or unexported fields
}

func ExposeDataMetrics

func ExposeDataMetrics(
	queueRepository repository.QueueRepository,
	jobRepository repository.JobRepository,
	usageRepository repository.UsageRepository,
	schedulingInfoRepository repository.SchedulingInfoRepository,
	queueMetrics QueueMetricProvider,
) *QueueInfoCollector

func (*QueueInfoCollector) Collect

func (c *QueueInfoCollector) Collect(metrics chan<- prometheus.Metric)

func (*QueueInfoCollector) Describe

func (c *QueueInfoCollector) Describe(desc chan<- *prometheus.Desc)

type QueueMetricProvider

type QueueMetricProvider interface {
	GetQueuedJobMetrics(queueName string) []*QueueMetrics
	GetRunningJobMetrics(queueName string) []*QueueMetrics
}

type QueueMetrics

type QueueMetrics struct {
	Pool          string
	PriorityClass string
	Resources     ResourceMetrics
	Durations     *FloatMetrics
}

type QueueMetricsRecorder

type QueueMetricsRecorder struct {
	Pool          string
	PriorityClass string
	// contains filtered or unexported fields
}

type ResourceMetrics

type ResourceMetrics map[string]*FloatMetrics

type ResourceMetricsRecorder

type ResourceMetricsRecorder struct {
	// contains filtered or unexported fields
}

func NewResourceMetricsRecorder

func NewResourceMetricsRecorder() *ResourceMetricsRecorder

func (*ResourceMetricsRecorder) GetMetrics

func (d *ResourceMetricsRecorder) GetMetrics() ResourceMetrics

func (*ResourceMetricsRecorder) Record

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL