Debian Codegraph @

exporter/exporterhelper/internal/queue/fg.go

raw symbols SCIP
1 // Copyright The OpenTelemetry Authors
2 // SPDX-License-Identifier: Apache-2.0
3
4 package queue // import "go.opentelemetry.io/collector/exporter/exporterhelper/internal/queue"
5
6 import "go.opentelemetry.io/collector/featuregate"
7
8 // PersistRequestContextFeatureGate controls whether request context should be preserved in the persistent queue.
9 var PersistRequestContextFeatureGate = featuregate.GlobalRegistry().MustRegister(
10 "exporter.PersistRequestContext",
11 featuregate.StageBeta,
12 featuregate.WithRegisterFromVersion("v0.128.0"),
13 featuregate.WithRegisterDescription("controls whether context should be stored alongside requests in the persistent queue"),
14 )
15
16 // assign the feature gate to separate functions to make it possible to override the behavior in tests
17 // on write and read paths separately.
18 var (
19 PersistRequestContextOnRead = PersistRequestContextFeatureGate.IsEnabled
20 PersistRequestContextOnWrite = PersistRequestContextFeatureGate.IsEnabled
21 )