allthingssecurity commented on PR #26769:
URL: https://github.com/apache/camel/pull/26769#issuecomment-5794136273
Thanks for the review. Both points are addressed in 1de2bd2f:
1. The setup phase of `testFailoverStickyTriesEachEndpointOnceWhenAllDown`
now also asserts that `a` and `b` each received exactly one (failed) attempt
before `c`.
2. New `testFailoverStickyWrapAroundRespectsMaximumFailoverAttempts` uses a
route with `failover(2, false, false, true)` over `a, b, c, d`:
- With `a` and `b` down, `c` becomes the last good endpoint.
- With everything down, it tries `c`, then `d`, then wraps to `a`. That
uses up the 2 failover attempts, so `b` is not tried and the exchange fails.
- With `a` back up, the exchange succeeds on `a` with the last allowed
attempt.
This shows the attempt counter covers the wrapped endpoints: the
`attempts > maximumFailoverAttempts` check runs before every move to the next
endpoint, including the wrap.
Without the fix, the new test fails (`mock://a Received message count.
Expected: <1> but was: <0>`). With it, all 22 `Failover*Test` / `FailOver*Test`
tests pass.
--
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]