SmallRye Fault Tolerance
SmallRye Fault Tolerance is an implementation of Eclipse MicroProfile Fault Tolerance.
Integration
Thread pools
A vendor may want to provide custom executor services for the fault tolerant executions. This can be achieved by creating a custom io.smallrye.faulttolerance.ExecutorFactory
and registering it via ServiceLoader
.
If multiple factories are discovered, the one with the highest priority is used.
Context Propagation
smallrye-fault-tolerance-context-propagation
provides an integration with MicroProfile Context Propagation. It is done by providing a custom ExecutorFactory
, namely ContextPropagationExecutorFactory
.
Please note that if you override the executor factory with a custom one and would like the context propagation to be enabled, you have to make sure your executor factory creates the executor services in the right way.
Open Tracing
SmallRye Fault Tolerance enables trace propagation to the asynchronous invocations via MicroProfile Context Propagation. To enable it, add smallrye-fault-tolerance-tracing-propagation
to your project
Configuration
SmallRye Fault Tolerance supports all the configuration options of MicroProfile Fault Tolerance and, additionally, the following options:
-
io.smallrye.faulttolerance.globalThreadPoolSize
, the amount of threads used by the fault tolerance mechanisms. This does not include bulkhead thread pools. Defaults to100
-
io.smallrye.faulttolerance.timeoutExecutorThreads
, the size of the thread pool used for scheduling timeouts. Defaults to5
Instructions
Compile and install this project:
mvn clean install
Project structure
-
implementation - Implementation of the Eclipse MicroProfile Fault Tolerance API.
-
tck - Test suite to run the implementation against the Eclipse MicroProfile Fault Tolerance TCK.
-
docs - Project documentation.