Documentation
¶
Index ¶
Constants ¶
View Source
const ( DiscoveryAPICacheRefreshMetricName = "agent_discoveryapi_cache_refresh_total" DiscoveryAPICacheRefreshMetricDescription = "The total number of Discovery API cache refresh attempts" DiscoveryAPICacheRefreshErrorMetricName = "agent_discoveryapi_cache_refresh_error_total" DiscoveryAPICacheRefreshErrorMetricDescription = "The total number of Discovery API cache refresh errors" ServiceReconciliationMetricName = "agent_service_reconciliations_total" ServiceReconciliationMetricDescription = "The total number of service reconciliations" ServiceReconciliationErrorMetricName = "agent_service_reconciliation_errors_total" ServiceReconciliationErrorMetricDescription = "The total number of service reconciliation errors" ServiceReconciliationDurationMetricName = "agent_service_reconcile_duration_seconds" ServiceReconciliationDurationMetricDescription = "The time it takes to reconcile a service" StackRunJobsCreatedMetricName = "agent_stack_runs_created_total" StackRunJobsCreatedMetricDescription = "The total number of created stack runs" ResourceCacheOpenWatchesName = "agent_resource_cache_open_watches_total" ResourceCacheOpenWatchesDescription = "The total number of open watches in the resource cache" ResourceCacheHitMetricName = "agent_resource_cache_hit_total" ResourceCacheHitMetricDescription = "The total number of resource cache hits" ResourceCacheMissMetricName = "agent_resource_cache_miss_total" ResourceCacheMissMetricDescription = "The total number of resource cache misses" MetricLabelServiceID = "service_id" MetricLabelServiceName = "service_name" MetricLabelServiceType = "service_type" MetricLabelServiceReconciliationStage = "service_reconciliation_stage" MetricLabelControllerName = "controller_name" ControllerRestartsMetricName = "agent_controller_restarts_total" ControllerRestartsMetricDescription = "The total number of controller restarts" SynchronizerEventMetricName = "agent_synchronizer_event_total" SynchronizerEventMetricDescription = "The total number of synchronizer events" MetricLabelSynchronizerEventType = "synchronizer_event_type" MetricLabelSynchronizerGroup = "synchronizer_group" MetricLabelSynchronizerVersion = "synchronizer_version" MetricLabelSynchronizerKind = "synchronizer_kind" )
Variables ¶
This section is empty.
Functions ¶
func FromContext ¶
func FromContext[T any](ctx context.Context, key ContextKey) (T, error)
Types ¶
type Recorder ¶
type Recorder interface {
DiscoveryAPICacheRefresh(err error)
ServiceReconciliation(serviceID, serviceName string, options ...ServiceReconciliationOption)
ServiceDeletion(serviceID string)
StackRunJobCreation()
ResourceCacheWatchStart(resourceType string)
ResourceCacheWatchEnd(resourceType string)
ResourceCacheWatchRemove(resourceType string)
ResourceCacheHit(serviceID string)
ResourceCacheMiss(serviceID string)
ControllerRestart(name string)
SynchronizationEvent(event watch.Event)
}
type ServiceReconciliationOption ¶
type ServiceReconciliationOption func(*serviceReconciliationOptions)
func WithServiceReconciliationError ¶
func WithServiceReconciliationError(err error) ServiceReconciliationOption
func WithServiceReconciliationStage ¶
func WithServiceReconciliationStage(stage ServiceReconciliationStage) ServiceReconciliationOption
func WithServiceReconciliationStartedAt ¶
func WithServiceReconciliationStartedAt(startedAt time.Time) ServiceReconciliationOption
type ServiceReconciliationStage ¶
type ServiceReconciliationStage string
const ( ServiceReconciliationStart ServiceReconciliationStage = "start" ServiceReconciliationPrepareManifestsFinish ServiceReconciliationStage = "prepare_manifests_finish" ServiceReconciliationApplyStart ServiceReconciliationStage = "apply_start" ServiceReconciliationApplyFinish ServiceReconciliationStage = "apply_finish" ServiceReconciliationUpdateStatusFinish ServiceReconciliationStage = "update_status_finish" ServiceReconciliationFinish ServiceReconciliationStage = "finish" )
func (ServiceReconciliationStage) String ¶
func (in ServiceReconciliationStage) String() string
Click to show internal directories.
Click to hide internal directories.