org.apache.hadoop.io.WritableDistCpProcedure, TrashProcedurepublic abstract class BalanceProcedure<T extends BalanceProcedure>
extends java.lang.Object
implements org.apache.hadoop.io.Writable
| Modifier and Type | Class | Description |
|---|---|---|
static class |
BalanceProcedure.RetryException |
The RetryException represents the current procedure should be delayed then
retried.
|
| Modifier and Type | Field | Description |
|---|---|---|
static org.slf4j.Logger |
LOG |
| Constructor | Description |
|---|---|
BalanceProcedure() |
|
BalanceProcedure(java.lang.String name,
long delayDuration) |
|
BalanceProcedure(java.lang.String name,
java.lang.String nextProcedure,
long delayDuration) |
The constructor of BalanceProcedure.
|
| Modifier and Type | Method | Description |
|---|---|---|
long |
delayMillisBeforeRetry() |
The time in milliseconds the procedure should wait before retry.
|
boolean |
equals(java.lang.Object obj) |
|
abstract boolean |
execute() |
The main process.
|
int |
hashCode() |
|
protected boolean |
isSchedulerShutdown() |
The active flag.
|
java.lang.String |
name() |
Get the procedure name.
|
java.lang.String |
nextProcedure() |
Get the next procedure.
|
void |
readFields(java.io.DataInput in) |
|
protected void |
setNextProcedure(java.lang.String nextProcedure) |
|
java.lang.String |
toString() |
|
void |
write(java.io.DataOutput out) |
public BalanceProcedure()
public BalanceProcedure(java.lang.String name,
java.lang.String nextProcedure,
long delayDuration)
name - the name of the procedure.nextProcedure - the name of the next procedure.delayDuration - the delay duration when this procedure is delayed.public BalanceProcedure(java.lang.String name,
long delayDuration)
public abstract boolean execute()
throws BalanceProcedure.RetryException,
java.io.IOException
BalanceProcedure.RetryException - if this procedure needs delay a while then retry.java.io.IOExceptionpublic long delayMillisBeforeRetry()
protected boolean isSchedulerShutdown()
protected void setNextProcedure(java.lang.String nextProcedure)
public java.lang.String nextProcedure()
public java.lang.String name()
public void write(java.io.DataOutput out)
throws java.io.IOException
write in interface org.apache.hadoop.io.Writablejava.io.IOExceptionpublic void readFields(java.io.DataInput in)
throws java.io.IOException
readFields in interface org.apache.hadoop.io.Writablejava.io.IOExceptionpublic int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2008–2025 Apache Software Foundation. All rights reserved.