metrics

package
v0.0.0-...-c6cbf5f Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	IngestHandlerRequests = func(slug, status, errorType string) prometheus.Counter {
		return ingestHandlerRequests.WithLabelValues(slug, status, errorType)
	}

	IngestedMessages = func(destinationId, status, errorType string) prometheus.Counter {
		return ingestedMessages.WithLabelValues(destinationId, status, errorType)
	}

	EventsHandlerRequests = func(destinationId, mode, tableName, status, errorType string) prometheus.Counter {
		return eventsHandlerRequests.WithLabelValues(destinationId, mode, tableName, status, errorType)
	}

	BulkHandlerRequests = func(destinationId, mode, tableName, status, errorType string) prometheus.Counter {
		return bulkHandlerRequests.WithLabelValues(destinationId, mode, tableName, status, errorType)
	}

	TopicManagerCreate = func(topicId, destinationId, mode, tableName, status, errorType string) prometheus.Counter {
		return topicManagerCreate.WithLabelValues(topicId, destinationId, mode, tableName, status, errorType)
	}

	TopicManagerError = func(errorType string) prometheus.Counter {
		return topicManagerError.WithLabelValues(errorType)
	}

	TopicManagerDestinations = func(mode, status string) prometheus.Gauge {
		return topicManagerDestinations.WithLabelValues(mode, status)
	}

	TopicManagerAbandonedTopics = promauto.NewGauge(prometheus.GaugeOpts{
		Namespace: "bulkerapp",
		Subsystem: "topic_manager",
		Name:      "abandoned_topics",
		Help:      "Number of abandoned topics. Abandoned topics are destination topics that are not used by any destination",
	})
	TopicManagerOtherTopics = promauto.NewGauge(prometheus.GaugeOpts{
		Namespace: "bulkerapp",
		Subsystem: "topic_manager",
		Name:      "other_topics",
		Help:      "Number of other topics. Other topics are any kafka topics not managed by the topic manager",
	})

	ProducerMessages = func(topicId, destinationId, mode, tableName, status, errorType string) prometheus.Counter {
		return producerMessages.WithLabelValues(topicId, destinationId, mode, tableName, status, errorType)
	}

	ProducerQueueLength = promauto.NewGauge(prometheus.GaugeOpts{
		Namespace: "bulkerapp",
		Subsystem: "producer",
		Name:      "queue_length",
	})

	ConsumerErrors = func(topicId, mode, destinationId, tableName, errorType string) prometheus.Counter {
		return consumerErrors.WithLabelValues(topicId, mode, destinationId, tableName, errorType)
	}

	ConsumerMessages = func(topicId, mode, destinationId, tableName, status string) prometheus.Counter {
		return consumerMessages.WithLabelValues(topicId, mode, destinationId, tableName, status)
	}

	ConsumerRuns = func(topicId, mode, destinationId, tableName, status string) prometheus.Counter {
		return consumerRuns.WithLabelValues(topicId, mode, destinationId, tableName, status)
	}

	RedisConfigurationSourceError = func(errorType string) prometheus.Counter {
		return redisConfigurationSourceError.WithLabelValues(errorType)
	}

	RedisConfigurationSourceDestinations = promauto.NewGauge(prometheus.GaugeOpts{
		Namespace: "bulkerapp",
		Subsystem: "redis_configuration",
		Name:      "destinations",
	})

	RepositoryDestinations = func(status string) prometheus.Counter {
		return repositoryDestinations.WithLabelValues(status)
	}

	RepositoryDestinationInitError = func(destinationId string) prometheus.Counter {
		return repositoryDestinationInitError.WithLabelValues(destinationId)
	}

	EventsLogError = func(errorType string) prometheus.Counter {
		return eventsLogError.WithLabelValues(errorType)
	}
)

Functions

func KafkaErrorCode

func KafkaErrorCode(err error) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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