Documentation ¶
Overview ¶
Package metrics to define all prometheus metric methods
Index ¶
- type Metrics
- type ReconcileCountMetrics
- func (am *ReconcileCountMetrics) DeleteMetrics(resourceType, name, namespace string)
- func (am *ReconcileCountMetrics) GetReconcileAttemptCounterValue(resourceType, appName, namespace string) int64
- func (am *ReconcileCountMetrics) InitMetrics(resourceType, name, namespace string)
- func (am *ReconcileCountMetrics) RegisterAllMetrics()
- func (am *ReconcileCountMetrics) RegisterReconcileAttempt(resourceType, appName, namespace string)
- func (am *ReconcileCountMetrics) RegisterReconcileDeleteAttempt(resourceType, appName, namespace string)
- func (am *ReconcileCountMetrics) RegisterReconcileDeleteFailed(resourceType, appName, namespace string)
- func (am *ReconcileCountMetrics) RegisterReconcileFailure(resourceType, appName, namespace string)
- func (am *ReconcileCountMetrics) RegisterReconcileSuccess(resourceType, appName, namespace string)
- type ReconcileTimeMetrics
- func (tm *ReconcileTimeMetrics) RegisterAllMetrics()
- func (tm *ReconcileTimeMetrics) RegisterDeployTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
- func (tm *ReconcileTimeMetrics) RegisterFetchTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
- func (tm *ReconcileTimeMetrics) RegisterOverallTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
- func (tm *ReconcileTimeMetrics) RegisterTemplateTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Metrics ¶ added in v0.50.0
type Metrics struct { *ReconcileCountMetrics *ReconcileTimeMetrics IsFirstReconcile bool }
Metrics holds all metrics
func NewMetrics ¶ added in v0.50.0
func NewMetrics() *Metrics
NewMetrics is a factory function that returns a new instance of Metrics.
type ReconcileCountMetrics ¶ added in v0.50.0
type ReconcileCountMetrics struct {
// contains filtered or unexported fields
}
ReconcileCountMetrics holds server metrics
func NewCountMetrics ¶ added in v0.50.0
func NewCountMetrics() *ReconcileCountMetrics
NewCountMetrics creates ReconcileCountMetrics object
func (*ReconcileCountMetrics) DeleteMetrics ¶ added in v0.50.0
func (am *ReconcileCountMetrics) DeleteMetrics(resourceType, name, namespace string)
DeleteMetrics deletes metrics
func (*ReconcileCountMetrics) GetReconcileAttemptCounterValue ¶ added in v0.50.0
func (am *ReconcileCountMetrics) GetReconcileAttemptCounterValue(resourceType, appName, namespace string) int64
GetReconcileAttemptCounterValue return reconcile count
func (*ReconcileCountMetrics) InitMetrics ¶ added in v0.50.0
func (am *ReconcileCountMetrics) InitMetrics(resourceType, name, namespace string)
InitMetrics initializes metrics
func (*ReconcileCountMetrics) RegisterAllMetrics ¶ added in v0.50.0
func (am *ReconcileCountMetrics) RegisterAllMetrics()
RegisterAllMetrics registers all prometheus metrics.
func (*ReconcileCountMetrics) RegisterReconcileAttempt ¶ added in v0.50.0
func (am *ReconcileCountMetrics) RegisterReconcileAttempt(resourceType, appName, namespace string)
RegisterReconcileAttempt increments reconcileAttemptTotal
func (*ReconcileCountMetrics) RegisterReconcileDeleteAttempt ¶ added in v0.50.0
func (am *ReconcileCountMetrics) RegisterReconcileDeleteAttempt(resourceType, appName, namespace string)
RegisterReconcileDeleteAttempt increments reconcileDeleteAttemptTotal
func (*ReconcileCountMetrics) RegisterReconcileDeleteFailed ¶ added in v0.50.0
func (am *ReconcileCountMetrics) RegisterReconcileDeleteFailed(resourceType, appName, namespace string)
RegisterReconcileDeleteFailed increments reconcileDeleteFailedTotal
func (*ReconcileCountMetrics) RegisterReconcileFailure ¶ added in v0.50.0
func (am *ReconcileCountMetrics) RegisterReconcileFailure(resourceType, appName, namespace string)
RegisterReconcileFailure increments reconcileFailureTotal
func (*ReconcileCountMetrics) RegisterReconcileSuccess ¶ added in v0.50.0
func (am *ReconcileCountMetrics) RegisterReconcileSuccess(resourceType, appName, namespace string)
RegisterReconcileSuccess increments reconcileSuccessTotal
type ReconcileTimeMetrics ¶ added in v0.50.0
type ReconcileTimeMetrics struct {
// contains filtered or unexported fields
}
ReconcileTimeMetrics holds reconcile time metrics
func NewReconcileTimeMetrics ¶ added in v0.50.0
func NewReconcileTimeMetrics() *ReconcileTimeMetrics
NewReconcileTimeMetrics creates ReconcileTimeMetrics object
func (*ReconcileTimeMetrics) RegisterAllMetrics ¶ added in v0.50.0
func (tm *ReconcileTimeMetrics) RegisterAllMetrics()
RegisterAllMetrics registers reconcile time prometheus metrics.
func (*ReconcileTimeMetrics) RegisterDeployTime ¶ added in v0.50.0
func (tm *ReconcileTimeMetrics) RegisterDeployTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
RegisterDeployTime sets deploy time
func (*ReconcileTimeMetrics) RegisterFetchTime ¶ added in v0.50.0
func (tm *ReconcileTimeMetrics) RegisterFetchTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
RegisterFetchTime sets fetch time
func (*ReconcileTimeMetrics) RegisterOverallTime ¶ added in v0.50.0
func (tm *ReconcileTimeMetrics) RegisterOverallTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
RegisterOverallTime sets overall time
func (*ReconcileTimeMetrics) RegisterTemplateTime ¶ added in v0.50.0
func (tm *ReconcileTimeMetrics) RegisterTemplateTime(resourceType, name, namespace string, firstReconcile bool, time time.Duration)
RegisterTemplateTime sets template time