surafel58 commented on issue #11911:
URL: https://github.com/apache/seatunnel/issues/11911#issuecomment-5366291438

   Thanks @SEZ9, this scoping is helpful and I agree with all of it. Plan for 
the implementation:
   
   - Put the retry inside flush() so every caller benefits (batch_size, timer 
flush, prepareCommit, close), not just the checkpoint path.
   - Reuse an existing retry helper rather than adding a new one. I will check 
RetryUtils (org.apache.seatunnel.common.utils) and how sibling connectors use 
it, and only add something new if nothing fits.
   - Retry policy: retry on transport errors and retryable HTTP statuses (5xx 
and 429), and fail fast on other 4xx client errors since those will not succeed 
on retry.
   - Expose max attempts and backoff (initial + cap) as sink options with 
conservative defaults, keeping retries bounded so a genuine outage still fails 
loudly after exhaustion.
   - Document the new options in the Prometheus sink docs (EN and ZH) and add a 
unit test that simulates a transient failure followed by success, plus one that 
exhausts retries and still throws.
   
   I will open the PR after #11827 merges, since both change flush() and doing 
this first would conflict with that PR. I would like to work on this one.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to