public abstract class AbstractCommitLogService
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected long |
lastSyncedAt |
protected java.util.concurrent.atomic.AtomicLong |
pending |
protected WaitQueue |
syncComplete |
Modifier and Type | Method and Description |
---|---|
void |
awaitTermination() |
void |
finishWriteFor(CommitLogSegment.Allocation alloc)
Block for @param alloc to be sync'd as necessary, and handle bookkeeping
|
long |
getCompletedTasks() |
long |
getPendingTasks() |
protected abstract void |
maybeWaitForSync(CommitLogSegment.Allocation alloc) |
void |
shutdown() |
void |
syncBlocking()
Request sync and wait until the current state is synced.
|
protected volatile long lastSyncedAt
protected final java.util.concurrent.atomic.AtomicLong pending
protected final WaitQueue syncComplete
public void finishWriteFor(CommitLogSegment.Allocation alloc)
protected abstract void maybeWaitForSync(CommitLogSegment.Allocation alloc)
public void shutdown()
public void syncBlocking()
public void awaitTermination() throws java.lang.InterruptedException
java.lang.InterruptedException
public long getCompletedTasks()
public long getPendingTasks()
Copyright © 2009-2021 The Apache Software Foundation