Previously, when both a per-sink S3 DLQ and a global failure pipeline
(dlq_pipeline) were configured, the failure pipeline always took
precedence. This meant the S3 DLQ configured on the OpenSearch sink
was never used.
This caused problems when the failure pipeline writes to the same
OpenSearch cluster that is experiencing issues — the failure pipeline
would also fail, blocking acknowledgements indefinitely (with acks
enabled) or causing negative acks upstream.
New priority order for handling failed documents:
1. S3 DLQ file writer (dlqFileWriter) — if configured
2. S3 DLQ writer (dlqWriter) — if configured on the sink
3. Failure pipeline (dlq_pipeline) — fallback if no sink-level DLQ
4. Log warning and release(false) — nothing configured
If S3 DLQ write fails, fall back to the failure pipeline. If no failure
pipeline exists either, release with false.
Signed-off-by: Taylor Gray <tylgry@amazon.com>
Previously, when both a per-sink S3 DLQ and a global failure pipeline (dlq_pipeline) were configured, the failure pipeline always took precedence. This meant the S3 DLQ configured on the OpenSearch sink was never used.
This caused problems when the failure pipeline writes to the same OpenSearch cluster that is experiencing issues — the failure pipeline would also fail, blocking acknowledgements indefinitely (with acks enabled) or causing negative acks upstream.
New priority order for handling failed documents:
If S3 DLQ write fails, fall back to the failure pipeline. If no failure pipeline exists either, release with false.
Description
[Describe what this change achieves]
Issues Resolved
Resolves #[Issue number to be closed when this PR is merged]
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.