Skip to content

Commit 2b95162

Browse files
authored
log the name of the state (open-telemetry#1440)
The int value of the state is not super helpful to end users. Logging the name of the state instead. Signed-off-by: Alex Boten <223565+codeboten@users.noreply.github.com>
1 parent f0d2b18 commit 2b95162

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

collector/internal/collector/collector.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ func (c *Collector) Start(ctx context.Context) error {
126126
case otelcol.StateRunning:
127127
return nil
128128
default:
129-
err = fmt.Errorf("unable to start, otelcol state is %d", state)
129+
err = fmt.Errorf("unable to start, otelcol state is %s", state.String())
130130
}
131131
}
132132
}

0 commit comments

Comments
 (0)