Skip to content

Commit 1434604

Browse files
authored
[receiver/otlpjsonfilereceiver]logs receive operations should use StartLogsOp/EndLogsOp (open-telemetry#14534)
* logs receive operations should use StartLogsOp/EndLogsOp
1 parent c67a02a commit 1434604

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

receiver/otlpjsonfilereceiver/file.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ func createLogsReceiver(_ context.Context, settings component.ReceiverCreateSett
8585
})
8686
cfg := configuration.(*Config)
8787
input, err := cfg.Config.Build(settings.Logger.Sugar(), func(ctx context.Context, attrs *fileconsumer.FileAttributes, token []byte) {
88-
ctx = obsrecv.StartMetricsOp(ctx)
88+
ctx = obsrecv.StartLogsOp(ctx)
8989
l, err := logsUnmarshaler.UnmarshalLogs(token)
9090
if err != nil {
9191
obsrecv.EndLogsOp(ctx, typeStr, 0, err)
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
2+
change_type: bug_fix
3+
4+
# The name of the component, or a single word describing the area of concern, (e.g. filelogreceiver)
5+
component: otlpjsonfilereceiver
6+
7+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
8+
note: logs receive operations should use StartLogsOp/EndLogsOp
9+
10+
issues: [14535]

0 commit comments

Comments
 (0)