Failover SPI provides developer with ability to supply custom logic for handling
failed execution of a grid job. Job execution can fail for a number of reasons:
- Job execution threw an exception (runtime, assertion or error)
- Node on which job was execution left topology (crashed or stopped)
- Collision SPI on remote node cancelled a job before it got a chance to execute (job rejection).
In all cases failover SPI takes failed job (as failover context) and list of all
grid nodes and provides another node on which the job execution will be retried.
It is up to failover SPI to make sure that job is not mapped to the node it
failed on. The failed node can be retrieved from
GridFailoverContext.getJobResult().node()
method.
Ignite comes with the following built-in failover SPI implementations:
NOTE: this SPI (i.e. methods in this interface) should never be used directly. SPIs provide
internal view on the subsystem and is used internally by Ignite kernal. In rare use cases when
access to a specific implementation of this SPI is required - an instance of this SPI can be obtained
via
Ignite.configuration()
method to check its configuration properties or call other non-SPI
methods. Note again that calling methods from this interface on the obtained instance can lead
to undefined behavior and explicitly not supported.