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

add metrics otelcol_exporter_queue_capacity #5475

Merged
merged 10 commits into from
Jul 19, 2022
Prev Previous commit
Next Next commit
fix unittest
Signed-off-by: Ziqi Zhao <[email protected]>
  • Loading branch information
fatsheep9146 committed Jul 17, 2022
commit d49b15293d01350d54190b423fc59765d3465f5f
2 changes: 1 addition & 1 deletion exporter/exporterhelper/queued_retry_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -342,11 +342,11 @@ func TestQueuedRetry_QueueMetricsReported(t *testing.T) {
be := newBaseExporter(&defaultExporterCfg, componenttest.NewNopExporterCreateSettings(), fromOptions(WithRetry(rCfg), WithQueue(qCfg)), "", nopRequestUnmarshaler())
require.NoError(t, be.Start(context.Background(), componenttest.NewNopHost()))

checkValueForGlobalManager(t, defaultExporterTags, int64(5000), "exporter/queue_capacity")
for i := 0; i < 7; i++ {
require.NoError(t, be.sender.send(newErrorRequest(context.Background())))
}
checkValueForGlobalManager(t, defaultExporterTags, int64(7), "exporter/queue_size")
checkValueForGlobalManager(t, defaultExporterTags, int64(5000), "exporter/queue_capacity")

assert.NoError(t, be.Shutdown(context.Background()))
checkValueForGlobalManager(t, defaultExporterTags, int64(0), "exporter/queue_size")
Expand Down