Modifier and Type | Field and Description |
---|---|
protected org.apache.hadoop.util.Progressable |
progressable
Progressable for reporting progress (Job context)
|
Constructor and Description |
---|
PredicateLock(org.apache.hadoop.util.Progressable progressable)
Constructor with default values.
|
PredicateLock(org.apache.hadoop.util.Progressable progressable,
int msecPeriod,
Time time)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
reset()
Reset the permanent signal.
|
void |
signal()
The event occurred and the occurrence has been logged for future
waiters.
|
void |
waitForTimeoutOrFail(long timeout)
Waits until timeout or fails with runtime exception.
|
boolean |
waitMsecs(int msecs)
Wait until the event occurred or waiting timed out.
|
protected final org.apache.hadoop.util.Progressable progressable
public PredicateLock(org.apache.hadoop.util.Progressable progressable)
progressable
- used to report progress() (usually a Mapper.Context)public PredicateLock(org.apache.hadoop.util.Progressable progressable, int msecPeriod, Time time)
progressable
- used to report progress() (usually a Mapper.Context)msecPeriod
- Msecs between progress reportstime
- Time implementationpublic void reset()
BspEvent
public void signal()
BspEvent
public boolean waitMsecs(int msecs)
BspEvent
public void waitForTimeoutOrFail(long timeout)
BspEvent
waitForTimeoutOrFail
in interface BspEvent
timeout
- Throws exception if waiting takes longer than timeout.Copyright © 2011-2020 The Apache Software Foundation. All Rights Reserved.