Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dist metrics #34

Merged
merged 4 commits into from
Jul 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@

<!-- 0.1.4 START -->
# 0.1.4 (04/07/2023)

- **[ENHANCEMENT]**: Add set of dashboards for monitoring deep [#22](https://github.com/intergral/deep/pull/22) [@Umaaz](https://github.com/Umaaz)
- **[BUGFIX]**: Handle error during query, when loading bad blocks [#26](https://github.com/intergral/deep/pull/26) [@Umaaz](https://github.com/Umaaz)
- **[BUGFIX]**: Ensure minio is started in distributed docker example [#24](https://github.com/intergral/deep/pull/24) [@Umaaz](https://github.com/Umaaz)
- **[BUGFIX]**: Handle nil when querier tracepoints, when we have no tracepoints [#23](https://github.com/intergral/deep/pull/23) [@Umaaz](https://github.com/Umaaz)
- **[CHANGE]**: Update metrics from ingester [#25](https://github.com/intergral/deep/pull/25) [@Umaaz](https://github.com/Umaaz)
- **[CHANGE]**: Update tenants dashboards [#27](https://github.com/intergral/deep/pull/27) [@Umaaz](https://github.com/Umaaz)
- **[CHANGE]**: Remove references to tempo/traces [#13](https://github.com/intergral/deep/pull/13) [@Umaaz](https://github.com/Umaaz)
- **[CHANGE]**: Disabled usage reports [#28](https://github.com/intergral/deep/pull/28) [@Umaaz](https://github.com/Umaaz)
<!-- 0.1.4 END -->

<!-- 0.1.3 START -->
# 0.1.3 (03/07/2023)

- **[ENHANCEMENT]**: Change distributor to support multi entry points [#20](https://github.com/intergral/deep/pull/20) [@Umaaz](https://github.com/Umaaz)
- **[BUGFIX]**: Handle possible error during tracepoint requests [#21](https://github.com/intergral/deep/pull/21) [@Umaaz](https://github.com/Umaaz)
<!-- 0.1.3 END -->

<!-- 0.1.2 START -->
# 0.1.2 (21/06/2023)

- **[ENHANCEMENT]**: Add perma links to docs [#9](https://github.com/intergral/deep/pull/9) [@Umaaz](https://github.com/Umaaz)
- **[ENHANCEMENT]**: Add examples for using kubernetes deployment files [#11](https://github.com/intergral/deep/pull/11) [@Umaaz](https://github.com/Umaaz)
- **[BUGFIX]**: Add exception to middleware auth [#10](https://github.com/intergral/deep/pull/10) [@Umaaz](https://github.com/Umaaz)
- **[BUGFIX]**: Fix tracepoint worker not working in single binary mode [#16](https://github.com/intergral/deep/pull/16) [@Umaaz](https://github.com/Umaaz)
- **[BUGFIX]**: Fix possible nil reference in store [#16](https://github.com/intergral/deep/pull/16) [@Umaaz](https://github.com/Umaaz)
- **[CHANGE]**: Make tracepoint storage use existing services [#14](https://github.com/intergral/deep/pull/14) [@Umaaz](https://github.com/Umaaz)
- **[CHANGE]**: **BREAKING** Remove unnecessary config embedding [#15](https://github.com/intergral/deep/pull/15) [@Umaaz](https://github.com/Umaaz)
<!-- 0.1.2 END -->

<!-- 0.1.1 START -->
# 0.1.1 (16/06/2023)

- **[FEATURE]**: change the queue/worker system to support tracepoints allowing for distributed mode deployments [#8](https://github.com/intergral/deep/pull/8) [@Umaaz](https://github.com/Umaaz)
<!-- 0.1.1 END -->

<!-- Template START
# 0.1.1 (16/06/2023)

- **[FEATURE]**: description [#PRid](https://github.com/intergral/deep/pull/) [@user](https://github.com/)
- **[ENHANCEMENT]**: description [#PRid](https://github.com/intergral/deep/pull/) [@user](https://github.com/)
- **[BUGFIX]**: description [#PRid](https://github.com/intergral/deep/pull/) [@user](https://github.com/)
- **[CHANGE]**: description [#PRid](https://github.com/intergral/deep/pull/8) [@user](https://github.com/)
Template END -->
28 changes: 19 additions & 9 deletions modules/distributor/distributor.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,54 +73,64 @@ const (
var (
metricDiscardedSnapshots = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Subsystem: "distributor",
Name: "discarded_snapshots_total",
Help: "The total number of samples that were discarded.",
}, []string{discardReasonLabel, "tenant"})
metricSnapshotBytesIngested = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_snapshot_bytes_received_total",
Subsystem: "distributor",
Name: "snapshot_bytes_received_total",
Help: "The total number of snapshot proto bytes received per tenant",
}, []string{"tenant"})
metricPollBytesIngested = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_poll_bytes_received_total",
Subsystem: "distributor",
Name: "poll_bytes_received_total",
Help: "The total number of poll proto bytes received per tenant",
}, []string{"tenant"})
metricPollBytesResponded = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_poll_bytes_sent_total",
Subsystem: "distributor",
Name: "poll_bytes_sent_total",
Help: "The total number of poll proto bytes sent in response per tenant",
}, []string{"tenant"})

metricIngesterAppends = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_ingester_appends_total",
Subsystem: "distributor",
Name: "ingester_appends_total",
Help: "The total number of batch appends sent to ingesters.",
}, []string{"ingester"})
metricIngesterAppendFailures = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_ingester_append_failures_total",
Subsystem: "distributor",
Name: "ingester_append_failures_total",
Help: "The total number of failed batch appends sent to ingesters.",
}, []string{"ingester"})

metricGeneratorPushes = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_metrics_generator_pushes_total",
Subsystem: "distributor",
Name: "metrics_generator_pushes_total",
Help: "The total number of span pushes sent to metrics-generators.",
}, []string{"metrics_generator"})
metricGeneratorPushesFailures = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_metrics_generator_pushes_failures_total",
Subsystem: "distributor",
Name: "metrics_generator_pushes_failures_total",
Help: "The total number of failed span pushes sent to metrics-generators.",
}, []string{"metrics_generator"})
metricIngesterClients = promauto.NewGauge(prometheus.GaugeOpts{
Namespace: "deep",
Name: "distributor_ingester_clients",
Subsystem: "distributor",
Name: "ingester_clients",
Help: "The current number of ingester clients.",
})
metricGeneratorClients = promauto.NewGauge(prometheus.GaugeOpts{
Namespace: "deep",
Name: "distributor_metrics_generator_clients",
Subsystem: "distributor",
Name: "metrics_generator_clients",
Help: "The current number of metrics-generator clients.",
})
)
Expand Down
6 changes: 4 additions & 2 deletions modules/distributor/forwarder.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,14 @@ const (
var (
metricForwarderPushes = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_forwarder_pushes_total",
Subsystem: "distributor",
Name: "forwarder_pushes_total",
Help: "Total number of successful requests queued up for a tenant to the generatorForwarder. This metric is now deprecated in favor of deep_distributor_queue_pushes_total.",
}, []string{"tenant"})
metricForwarderPushesFailures = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_forwarder_pushes_failures_total",
Subsystem: "distributor",
Name: "forwarder_pushes_failures_total",
Help: "Total number of failed pushes to the queue for a tenant to the generatorForwarder. This metric is now deprecated in favor of deep_distributor_queue_pushes_failures_total.",
}, []string{"tenant"})
)
Expand Down
18 changes: 12 additions & 6 deletions modules/distributor/snapshotreceiver/reciever.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,36 +45,42 @@ const (
var (
metricPollDuration = promauto.NewHistogram(prometheus.HistogramOpts{
Namespace: "deep",
Name: "distributor_poll_duration_seconds",
Subsystem: "distributor",
Name: "poll_duration_seconds",
Help: "Records the amount of time to poll a config from tracepoint.",
Buckets: prometheus.DefBuckets,
})
metricPushDuration = promauto.NewHistogram(prometheus.HistogramOpts{
Namespace: "deep",
Name: "distributor_push_duration_seconds",
Subsystem: "distributor",
Name: "push_duration_seconds",
Help: "Records the amount of time to push a batch to the ingester.",
Buckets: prometheus.DefBuckets,
})

metricDistributorAccepted = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_snapshots_requests",
Subsystem: "distributor",
Name: "snapshots_requests",
Help: "Number of snapshots successfully pushed into the pipeline.",
}, []string{"tenant", "receiver"})
metricPollAccepted = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_poll_requests",
Subsystem: "distributor",
Name: "poll_requests",
Help: "Number of completed poll requests.",
}, []string{"tenant", "receiver"})

metricDistributorRefused = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_failed_snapshots_requests",
Subsystem: "distributor",
Name: "failed_snapshots_requests",
Help: "Number of snapshots that could not be pushed into the pipeline.",
}, []string{"tenant", "receiver"})
metricPollRefused = promauto.NewCounterVec(prometheus.CounterOpts{
Namespace: "deep",
Name: "distributor_failed_poll_requests",
Subsystem: "distributor",
Name: "failed_poll_requests",
Help: "Number of failed poll requests.",
}, []string{"tenant", "receiver"})
)
Expand Down