Fault Tolerance 4.1
MicroProfile Fault Tolerance 2.1 was released just 2 weeks ago, and it didn’t take us long to fully implement. Today, we announce availability of SmallRye Fault Tolerance 4.1, a compliant implementation of MicroProfile Fault Tolerance 2.1. Here’s a list of the important changes in the specification:
-
The
@Retry.retryOnandabortOnattributes no longer ignoreThrowable.class, to be consistent with other annotations that also specify exceptions. Only@Retryhad a requirement thatThrowableis to be ignored. -
Related to the previous item is that the specification now admits that throwing custom
Throwables results in nonportable behavior. Fortunately, the use cases for throwing something that isn’t anException(nor anError) should be very rare. -
Also, the behavior was previously unspecified when the
@Retry.retryOnandabortOnattributes overlap. It is now specified that theabortOnattribute "wins" overretryOn. -
The
@CircuitBreaker.skipOnattribute was added, to complement the existingfailOnattribute. When the attributes overlap,skipOn"wins" overfailOn. -
The
@Fallback.applyOnandskipOnattributes were also added. When they overlap,skipOn"wins" overapplyOn. -
It is now specified that during the
@Asynchronousmethod execution, the CDI request context is always active. The specification previously did not require that.
This release is also aligned with other SmallRye projects (Config and Metrics) that also recently released a new version in preparation of MicroProfile 3.3 platform release.
Enjoy the new SmallRye Fault Tolerance, it is coming in the next Quarkus release!