Skip to content

Commit 0ddedf0

Browse files
authored
[service] move useOtelWithSDKConfigurationForInternalTelemetry gate to beta (#11091)
#### Description This configuration of the internal collector telemetry has been using the SDK configuration for some time. Moving this gate from alpha to beta. #### Link to tracking issue Related to #6629 --------- Signed-off-by: Alex Boten <[email protected]>
1 parent 6ea5b69 commit 0ddedf0

File tree

3 files changed

+29
-5
lines changed

3 files changed

+29
-5
lines changed
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Use this changelog template to create an entry for release notes.
2+
3+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
4+
change_type: enhancement
5+
6+
# The name of the component, or a single word describing the area of concern, (e.g. otlpreceiver)
7+
component: service
8+
9+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
10+
note: "move `useOtelWithSDKConfigurationForInternalTelemetry` gate to beta"
11+
12+
# One or more tracking issues or pull requests related to the change
13+
issues: [11091]
14+
15+
# (Optional) One or more lines of additional information to render under the primary note.
16+
# These lines will be padded with 2 spaces and then inserted directly into the document.
17+
# Use pipe (|) for multiline entries.
18+
subtext:
19+
20+
# Optional: The change log or logs in which this entry should be included.
21+
# e.g. '[user]' or '[user, api]'
22+
# Include 'user' if the change is relevant to end users.
23+
# Include 'api' if there is a change to a library API.
24+
# Default: '[user]'
25+
change_logs: []

internal/obsreportconfig/obsreportconfig.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,6 @@ var DisableHighCardinalityMetricsfeatureGate = featuregate.GlobalRegistry().Must
1919
// supports configuring the OpenTelemetry SDK via configuration
2020
var UseOtelWithSDKConfigurationForInternalTelemetryFeatureGate = featuregate.GlobalRegistry().MustRegister(
2121
"telemetry.useOtelWithSDKConfigurationForInternalTelemetry",
22-
featuregate.StageAlpha,
22+
featuregate.StageBeta,
2323
featuregate.WithRegisterDescription("controls whether the collector supports extended OpenTelemetry"+
2424
"configuration for internal telemetry"))

service/service.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ type Service struct {
8989
// New creates a new Service, its telemetry, and Components.
9090
func New(ctx context.Context, set Settings, cfg Config) (*Service, error) {
9191
disableHighCard := obsreportconfig.DisableHighCardinalityMetricsfeatureGate.IsEnabled()
92-
extendedConfig := obsreportconfig.UseOtelWithSDKConfigurationForInternalTelemetryFeatureGate.IsEnabled()
9392

9493
srv := &Service{
9594
buildInfo: set.BuildInfo,
@@ -141,7 +140,7 @@ func New(ctx context.Context, set Settings, cfg Config) (*Service, error) {
141140
return nil, fmt.Errorf("failed to create metric provider: %w", err)
142141
}
143142

144-
logsAboutMeterProvider(logger, cfg.Telemetry.Metrics, mp, extendedConfig)
143+
logsAboutMeterProvider(logger, cfg.Telemetry.Metrics, mp)
145144
srv.telemetrySettings = component.TelemetrySettings{
146145
LeveledMeterProvider: func(level configtelemetry.Level) metric.MeterProvider {
147146
if level <= cfg.Telemetry.Metrics.Level {
@@ -183,7 +182,7 @@ func New(ctx context.Context, set Settings, cfg Config) (*Service, error) {
183182
return srv, nil
184183
}
185184

186-
func logsAboutMeterProvider(logger *zap.Logger, cfg telemetry.MetricsConfig, mp metric.MeterProvider, extendedConfig bool) {
185+
func logsAboutMeterProvider(logger *zap.Logger, cfg telemetry.MetricsConfig, mp metric.MeterProvider) {
187186
if cfg.Level == configtelemetry.LevelNone || (cfg.Address == "" && len(cfg.Readers) == 0) {
188187
logger.Info(
189188
"Skipped telemetry setup.",
@@ -193,7 +192,7 @@ func logsAboutMeterProvider(logger *zap.Logger, cfg telemetry.MetricsConfig, mp
193192
return
194193
}
195194

196-
if len(cfg.Address) != 0 && extendedConfig {
195+
if len(cfg.Address) != 0 && obsreportconfig.UseOtelWithSDKConfigurationForInternalTelemetryFeatureGate.IsEnabled() {
197196
logger.Warn("service::telemetry::metrics::address is being deprecated in favor of service::telemetry::metrics::readers")
198197
}
199198

0 commit comments

Comments
 (0)