public class IgniteSchedulerImpl extends Object implements IgniteScheduler, Externalizable
IgniteScheduler
implementation.Constructor and Description |
---|
IgniteSchedulerImpl()
Required by
Externalizable . |
IgniteSchedulerImpl(GridKernalContext ctx) |
Modifier and Type | Method and Description |
---|---|
<R> IgniteFuture<R> |
callLocal(@NotNull Callable<R> c)
Executes given callable on internal system thread pool asynchronously.
|
void |
readExternal(ObjectInput in) |
IgniteFuture<?> |
runLocal(@NotNull Runnable r)
Executes given closure on internal system thread pool asynchronously.
|
Closeable |
runLocal(@NotNull Runnable r,
long delay,
TimeUnit timeUnit)
Executes given closure after the delay.
|
<R> SchedulerFuture<R> |
scheduleLocal(@NotNull Callable<R> job,
String ptrn)
Schedules job for execution using local cron-based scheduling.
|
SchedulerFuture<?> |
scheduleLocal(@NotNull Runnable job,
String ptrn)
Schedules job for execution using local cron-based scheduling.
|
void |
writeExternal(ObjectOutput out) |
public IgniteSchedulerImpl()
Externalizable
.public IgniteSchedulerImpl(GridKernalContext ctx)
ctx
- Kernal context.public IgniteFuture<?> runLocal(@NotNull @NotNull Runnable r)
Note that class IgniteRunnable
implements Runnable
and class IgniteOutClosure
implements Callable
interface.
runLocal
in interface IgniteScheduler
r
- Not null runnable to execute.IgniteScheduler.callLocal(Callable)
,
IgniteClosure
public Closeable runLocal(@NotNull @NotNull Runnable r, long delay, TimeUnit timeUnit)
Note that class IgniteRunnable
implements Runnable
runLocal
in interface IgniteScheduler
r
- Not null runnable to execute.delay
- Initial delay.timeUnit
- Time granularity.public <R> IgniteFuture<R> callLocal(@NotNull @NotNull Callable<R> c)
Note that class IgniteRunnable
implements Runnable
and class IgniteOutClosure
implements Callable
interface.
callLocal
in interface IgniteScheduler
R
- Type of the return value for the closure.c
- Not null callable to execute.IgniteScheduler.runLocal(Runnable)
,
IgniteOutClosure
public SchedulerFuture<?> scheduleLocal(@NotNull @NotNull Runnable job, String ptrn)
scheduleLocal
in interface IgniteScheduler
job
- Not null job to schedule to run as a background cron-based job.ptrn
- Scheduling pattern in UNIX cron format with optional prefix {n1, n2}
where n1
is delay of scheduling in seconds and n2
is the number of execution. Both
parameters are optional.public <R> SchedulerFuture<R> scheduleLocal(@NotNull @NotNull Callable<R> job, String ptrn)
scheduleLocal
in interface IgniteScheduler
job
- Not null job to schedule to run as a background cron-based job.ptrn
- Scheduling pattern in UNIX cron format with optional prefix {n1, n2}
where n1
is delay of scheduling in seconds and n2
is the number of execution. Both
parameters are optional.public void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
IOException
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
IOException
ClassNotFoundException
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.9.0 Release Date : October 15 2020