|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.sgs.impl.kernel.schedule.ImmediateRetryPolicy
public class ImmediateRetryPolicy
A simple retry "in place" SchedulerRetryPolicy. This
SchedulerRetryPolicy always causes a task that throws a
retryable exception to retry immediately. This class supports the following
configuration properties:
"com.sun.sgs.impl.kernel.schedule.retry.warning.threshold"
WARNING
message will be logged as feedback to the user. This value must be
greater than or equal to 1.
| Field Summary | |
|---|---|
(package private) static int |
DEFAULT_RETRY_WARNING_THRESHOLD
The default retry warning threshold |
(package private) static String |
RETRY_WARNING_THRESHOLD_PROPERTY
The property used to define the retry count threshold to use before printing a WARNING message. |
| Constructor Summary | |
|---|---|
ImmediateRetryPolicy(Properties properties)
Constructs an ImmediateRetryPolicy. |
|
| Method Summary | |
|---|---|
SchedulerRetryAction |
getRetryAction(ScheduledTask task)
Determines if and how a task should be retried after a failure. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
static final String RETRY_WARNING_THRESHOLD_PROPERTY
static final int DEFAULT_RETRY_WARNING_THRESHOLD
| Constructor Detail |
|---|
public ImmediateRetryPolicy(Properties properties)
ImmediateRetryPolicy.
properties - the system properties available| Method Detail |
|---|
public SchedulerRetryAction getRetryAction(ScheduledTask task)
SchedulerRetryAction.DROP means that the
task should be dropped and not retried.SchedulerRetryAction.RETRY_LATER means that
the task should be retried by the scheduler at some point in the
future.SchedulerRetryAction.RETRY_NOW means that
the task should be retried immediately.task in order to affect
how the scheduler behaves when re-executing.
Note: The Throwable cause of the most recent failure of the given
task should always be accessible via the
ScheduledTask.getLastFailure() method. This Throwable
may implement ExceptionRetryStatus. If it does, care
should be taken to abide by the contract specified by the
TaskManager with regard to Throwables that implement
this interface.
Note: The proper way to drop a task with a custom policy is to return
DROP with this method. Implementations should not
use a call to cancel on the
given task.
getRetryAction in interface SchedulerRetryPolicytask - the task that has been aborted
SchedulerRetryAction that the scheduler should
take with respect to retrying the given task
|
RedDwarf, Version 0.10.1 2010-03-14 10:56:12 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||