He-Pin opened a new pull request, #3435: URL: https://github.com/apache/pekko/pull/3435
### Motivation The Java DSL `Patterns.retry` with `Predicate2` (shouldRetry) has been available since 1.1.0 but lacks a directional test exercising the short-circuit behavior from Java. The Scala DSL has coverage in `RetrySpec` but the Java path is untested. ### Modification Add `testShortCircuitRetry` to `PatternsTest.java` that verifies: - Retry continues when predicate returns true (`IllegalStateException`) - Retry stops immediately when predicate returns false (`IllegalArgumentException`) - Exactly 3 attempts are made (2 retriable + 1 non-retriable) ### Result Java DSL retry short-circuit behavior is now covered by a directional test that would fail if the `Predicate2` wiring were broken. ### Tests - `sbt "actor-tests / Test / testOnly org.apache.pekko.pattern.PatternsTest"` ### References Refs akka/akka-core#32035 -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
