-
Notifications
You must be signed in to change notification settings - Fork 5k
otel: add test for otelconsumer + elasticsearchexporter document-level retries #46413
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
Conversation
🤖 GitHub commentsExpand to view the GitHub comments
Just comment with:
|
Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane) |
7a0f602
to
59942e6
Compare
05af572
to
56a5e5c
Compare
/test |
This pull request is now in conflicts. Could you fix it? 🙏
|
/test |
This is ready for review now, pending CI. |
This pull request is now in conflicts. Could you fix it? 🙏
|
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.
LGTM, just a nit.
19ac3fe
to
05a4cbf
Compare
TestFilestreamTruncateBlockedOutput is flaking https://github.com/elastic/ingest-dev/issues/6087. Edit: Fix here #46576. |
@cmacknz When you have a chance, could you please review this and approve if it looks good? Thanks! |
@Mergifyio backport 9.0 9.1 |
✅ Backports have been created
|
…l retries (#46413) * otel: add test for document-level retries * fix linter errors * add dummy assert for dropped events * use deterministic handler from mock-es * assert mock-es metrics * sync go.mod and go.sum * simplify handler logic * update comments * use slices.Contains * go get mock-es latest (cherry picked from commit 2948886) # Conflicts: # NOTICE.txt # go.mod # go.sum # x-pack/filebeat/tests/integration/otel_test.go
…l retries (#46413) * otel: add test for document-level retries * fix linter errors * add dummy assert for dropped events * use deterministic handler from mock-es * assert mock-es metrics * sync go.mod and go.sum * simplify handler logic * update comments * use slices.Contains * go get mock-es latest (cherry picked from commit 2948886) # Conflicts: # NOTICE.txt # go.mod # go.sum # x-pack/filebeat/tests/integration/otel_test.go
…l retries (#46413) * otel: add test for document-level retries * fix linter errors * add dummy assert for dropped events * use deterministic handler from mock-es * assert mock-es metrics * sync go.mod and go.sum * simplify handler logic * update comments * use slices.Contains * go get mock-es latest (cherry picked from commit 2948886) # Conflicts: # NOTICE.txt # go.mod # go.sum # x-pack/filebeat/tests/integration/otel_test.go
Proposed commit message
This commit adds a test to verify that
elasticsearchexporter
appliesdocument-level retries correctly, and that the combination of
otelconsumer
and the exporter guarantees at-least-once delivery whena batch is acknowledged.
The test simulates retryable and permanent errors, checks that
max_retries
is respected, and ensures that documents retried aftertemporary failures are ingested while permanent failures are dropped.
Currenty, otelconsumer output metrics are not tracked correctly, and it
will always ACK the whole batch even if there were retries or dropped
events by the exporter.
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.How to test this PR locally
Related issues
sending_queue
from [beatreceiver] - Disableforce_attempt_http2
and map ES config to elasticsearchexporter #46111