Repository navigation
New API since 1.1.1, all of it additive: code generated by a 1.0.x or 1.1.x processor keeps running on 1.2.0, and the configuration is unchanged. One build can now fail that used to pass: a Spring Boot native image with resilience4cata beans and no generated classes fails during AOT processing, where it used to run them unprotected.
Added
- Force a circuit breaker open, or reset it, through the Spring Boot and Micronaut endpoints:
POST …/resilience4cata/{instance}with{"circuitBreaker": "force-open"}or"reset"calls the breaker'sforceOpen()orreset()and answers with the instance's snapshot. Spring Boot answers only once the endpoint's access isunrestricted; on Micronaut the operation stays sensitive untilendpoints.resilience4cata.write-sensitiveisfalse(Spring Boot, Micronaut). - Handles for retries, hedges and timeouts:
registry.retry(id),hedge(id)andtimeout(id)return aRetryHandle,HedgeHandleandTimeoutHandle(id(),config(),snapshot()), like the other policies' (Handles). registry.addInstanceListener(…): called with each new instance as aPolicyInstance, itsPolicyKindand id, so a metrics bridge can look up that one handle (Another metrics library).ConfigException.details(): each problem's code apart from its message, asConfigProblemrecords, for code that handles problems by code (Configuration).Ticker.addAdvanceListener(…)returns aRegistrationthat removes the listener; testkit'sManualClockimplements it. A registry that is no longer reachable now stops listening to its ticker, so oneManualClockcan serve many registries without keeping them alive (Testing).Resilient.shutdownThreads(Duration)stops the library's own threads, for a web application that a servlet container undeploys or reloads while the JVM keeps running: they no longer keep its class loader alive (Troubleshooting).- Spring Boot native images: a missing annotation processor fails the build. The R4C-SPR-006 check now also runs during Spring's AOT processing, so a bean with resilience4cata annotations and no generated class fails the native build instead of running unprotected in the image (R4C-SPR-006).
- The timeout watchdog's and the async timer's ticks grow back once the timeouts that needed a short one are gone (their registry dropped, their application reloaded), instead of staying at the shortest ever used (Timeout).
Install: dev.resilience4cata:resilience4cata-bom:1.2.0 (installation). Full changelog: https://resilience4cata.dev/en/changelog