MCPcopy
hub / github.com/prometheus/prometheus / newTestQueueManager

Function newTestQueueManager

storage/remote/queue_manager_test.go:306–312  ·  view source on GitHub ↗
(t testing.TB, cfg config.QueueConfig, mcfg config.MetadataConfig, deadline time.Duration, c WriteClient, protoMsg remoteapi.WriteMessageType)

Source from the content-addressed store, hash-verified

304}
305
306func newTestQueueManager(t testing.TB, cfg config.QueueConfig, mcfg config.MetadataConfig, deadline time.Duration, c WriteClient, protoMsg remoteapi.WriteMessageType) *QueueManager {
307 dir := t.TempDir()
308 metrics := newQueueManagerMetrics(nil, "", "")
309 m := NewQueueManager(metrics, nil, nil, nil, dir, newEWMARate(ewmaWeight, shardUpdateDuration), cfg, mcfg, labels.EmptyLabels(), nil, c, deadline, newPool(), newHighestTimestampMetric(), nil, false, false, false, protoMsg, record.NewBuffersPool())
310
311 return m
312}
313
314func testDefaultQueueConfig() config.QueueConfig {
315 cfg := config.DefaultQueueConfig

Callers 12

TestShutdownFunction · 0.85
TestSeriesResetFunction · 0.85
TestReshardFunction · 0.85
TestReshardRaceWithStopFunction · 0.85
TestReshardPartialBatchFunction · 0.85
TestQueueFilledDeadlockFunction · 0.85
BenchmarkSampleSendFunction · 0.85
TestDropOldTimeSeriesFunction · 0.85

Calls 7

EmptyLabelsFunction · 0.92
NewBuffersPoolFunction · 0.92
newQueueManagerMetricsFunction · 0.85
NewQueueManagerFunction · 0.85
newEWMARateFunction · 0.85
newPoolFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…