@InterfaceAudience.Private @InterfaceStability.Unstable public class FlushSnapshotSubprocedure extends Subprocedure
Modifier and Type | Class and Description |
---|---|
static class |
FlushSnapshotSubprocedure.RegionSnapshotTask
Callable for adding files to snapshot manifest working dir.
|
Subprocedure.SubprocedureImpl
Modifier and Type | Field and Description |
---|---|
private static org.slf4j.Logger |
LOG |
(package private) static int |
MAX_RETRIES |
private List<HRegion> |
regions |
private org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos.SnapshotDescription |
snapshot |
private boolean |
snapshotSkipFlush |
private RegionServerSnapshotManager.SnapshotSubprocedurePool |
taskManager |
executionTimeoutTimer, monitor, rpcs, wakeFrequency
Constructor and Description |
---|
FlushSnapshotSubprocedure(ProcedureMember member,
ForeignExceptionDispatcher errorListener,
long wakeFrequency,
long timeout,
List<HRegion> regions,
org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos.SnapshotDescription snapshot,
RegionServerSnapshotManager.SnapshotSubprocedurePool taskManager) |
Modifier and Type | Method and Description |
---|---|
void |
acquireBarrier()
do nothing, core of snapshot is executed in
insideBarrier() step. |
void |
cleanup(Exception e)
Cancel threads if they haven't finished.
|
private void |
flushSnapshot() |
byte[] |
insideBarrier()
do a flush snapshot of every region on this rs from the target table.
|
void |
releaseBarrier()
Hooray!
|
call, cancel, getMemberName, getName, receiveReachedGlobalBarrier, waitForLocallyCompleted
private static final org.slf4j.Logger LOG
private final org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos.SnapshotDescription snapshot
private final RegionServerSnapshotManager.SnapshotSubprocedurePool taskManager
private boolean snapshotSkipFlush
static final int MAX_RETRIES
public FlushSnapshotSubprocedure(ProcedureMember member, ForeignExceptionDispatcher errorListener, long wakeFrequency, long timeout, List<HRegion> regions, org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos.SnapshotDescription snapshot, RegionServerSnapshotManager.SnapshotSubprocedurePool taskManager)
private void flushSnapshot() throws ForeignException
ForeignException
public void acquireBarrier() throws ForeignException
insideBarrier()
step.acquireBarrier
in class Subprocedure
ForeignException
public byte[] insideBarrier() throws ForeignException
insideBarrier
in class Subprocedure
ForeignException
public void cleanup(Exception e)
cleanup
in class Subprocedure
public void releaseBarrier()
Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.