@Documented @Retention(value=RUNTIME) @Target(value={METHOD,FIELD}) public @interface IgniteInstanceResource
Ignite
instance.
It can be injected into grid tasks and grid jobs. Note that grid instance will
not be injected into SPI's, as there is no grid during SPI start.
Grid instance can be injected into instances of following classes:
ComputeTask
ComputeJob
LifecycleBean
Here is how injection would typically happen:
public class MyIgniteJob implements ComputeJob { ... @IgniteInstanceResource private Ignite ignite; ... }or
public class MyIgniteJob implements ComputeJob { ... private Ignite ignite; ... @IgniteInstanceResource public void setIgnite(Ignite ignite) { this.ignite = ignite; } ... }
GridGain In-Memory Computing Platform : ver. 8.9.14 Release Date : November 5 2024