fix(otel): ensure default processors are applied in fbreceiver#42658
fix(otel): ensure default processors are applied in fbreceiver#42658mauri870 merged 3 commits intoelastic:mainfrom
Conversation
e1456a5 to
c1bb6e1
Compare
|
Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane) |
leehinman
left a comment
There was a problem hiding this comment.
This definitely fixes the immediate issue.
Longer term though, I'm not sure if we want to always assume that a Beat Receiver will use the default processors.
Maybe change it so that we look at something in the config passed to NewBeatReceiver, and set a field called "UseDefaultProcessors" accordingly in Info. Would need to be before
beats/libbeat/cmd/instance/beat.go
Line 443 in 7514fa9
What do you think?
|
Thanks, makes total sense. I'll make the necessary changes. |
aa7be28 to
061af6b
Compare
|
|
||
| // NewBeatReceiver creates a Beat that will be used in the context of an otel receiver | ||
| func NewBeatReceiver(settings Settings, receiverConfig map[string]interface{}, consumer consumer.Logs, core zapcore.Core) (*Beat, error) { | ||
| func NewBeatReceiver(settings Settings, receiverConfig map[string]interface{}, useDefaultProcessors bool, consumer consumer.Logs, core zapcore.Core) (*Beat, error) { |
There was a problem hiding this comment.
Having the option inside receiverConfig is also possible, but it only contains the Beats configuration, so I'd have to remove the key from the map. Being explicit here seems more appropriate.
* fix(otel): ensure default processors are applied in fbreceiver * set default processors in NewBeatReceiver (cherry picked from commit d813311)
* fix(otel): ensure default processors are applied in fbreceiver * set default processors in NewBeatReceiver (cherry picked from commit d813311)
Proposed commit message
Currently default processors are only applied under fleet management. Enable default processors for beats when running under OTel receiver mode.
Checklist
CHANGELOG.next.asciidocorCHANGELOG-developer.next.asciidoc.Related issues