-
Notifications
You must be signed in to change notification settings - Fork 149
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
otel: add test for batch splitting with the elasticsearchexporter #6334
Conversation
Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane) |
This pull request does not have a backport label. Could you fix it @mauri870? 🙏
|
|
d42229b
to
3519ee7
Compare
Quality Gate passedIssues Measures |
@mauri870 does this PR fixes https://github.com/elastic/ingest-dev/issues/3677? After reading the description I am not sure what the |
// This test asserts that the batcher configuration from the elasticseachexporter | ||
// splits batches to avoid a 413 Request Entity Too Large error from Elasticsearch. | ||
info := define.Require(t, define.Requirements{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just double checking why we need this to be an integration test that runs the entire collector. What additional test coverage is this adding? Why can't this be covered by a unit test in the exporter?
I like integration tests, they catch a lot of problems, but they are also driving our CI execution time to infinity :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree, I think this is better suited to be in the exporter. Actually, it might as well be covered in the exporter already by open-telemetry/opentelemetry-collector-contrib#36396. I will double check.
"For" in this context means "Relates to" that issue. Unfortunately the issue is an umbrella to different corner cases that need to be covered, and this PR is a test for one of them. |
So I looked into the tests and the elasticsearchexporter has coverage of test options, including flush::interval and flush::bytes here, I don't think an integration test in this case adds any additional coverage. |
What does this PR do?
Adds a test that the elasticsearchexporter does batch splitting properly on large batches comming from a beats receiver.
Why is it important?
This guarantees that the scenario covered in elastic/beats#41911 does not happen again.
Checklist
./changelog/fragments
using the changelog toolRelated issues