refactor: restore parameterless NewFactory functions for Beat receivers#49571
refactor: restore parameterless NewFactory functions for Beat receivers#49571andrzej-stencel wants to merge 2 commits intoelastic:mainfrom
Conversation
To keep them compatible with OpenTelemetry Collector Builder.
🤖 GitHub commentsJust comment with:
|
Both changes will land in the same release, so the second change doesn't break anything.
|
Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane) |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (8)
📝 WalkthroughWalkthroughRefactored receiver factory constructors across filebeat and metricbeat modules. Renamed the existing parameterized factory functions to ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Comment Tip You can make CodeRabbit's review stricter and more nitpicky using the `assertive` profile, if that's what you prefer.Change the |
To keep them compatible with OpenTelemetry Collector Builder.
Proposed commit message
Restores parameterless
NewFactoryfunctions for Filebeat receiver and Metricbeat receiver to keep their API compatible with OpenTelemetry Collector Builder, which requires parameterlessNewFactoryfunction.The function
NewFactoryWithSettings(Settings)has been introduced for use in the Elastic Agent to inject settings in runtime.Relates NewFactory for beatreceivers takes default home and data dirs #49327
Relates [beats receivers] Using Filebeat modules or Metricbeat lightweight modules requires manually setting home path to the components directory elastic-agent#11734
Checklist
[ ] I have made corresponding changes to the documentation[ ] I have made corresponding change to the default configuration filesstresstest.shscript to run them under stress conditions and race detector to verify their stability../changelog/fragmentsusing the changelog tool.