public class RemoteTierConsumerAgent extends Object implements TierConsumerAgent
| Constructor and Description |
|---|
RemoteTierConsumerAgent(RemoteStorageScanner remoteStorageScanner,
PartitionFileReader partitionFileReader,
int bufferSizeBytes) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the consumer agent.
|
Optional<Buffer> |
getNextBuffer(TieredStoragePartitionId partitionId,
TieredStorageSubpartitionId subpartitionId,
int segmentId)
Get buffer from the consumer agent.
|
void |
registerAvailabilityNotifier(AvailabilityNotifier notifier)
Register the notifier to notify the availability of a subpartition.
|
void |
start()
Start the consumer agent.
|
public RemoteTierConsumerAgent(RemoteStorageScanner remoteStorageScanner, PartitionFileReader partitionFileReader, int bufferSizeBytes)
public void start()
TierConsumerAgentstart in interface TierConsumerAgentpublic Optional<Buffer> getNextBuffer(TieredStoragePartitionId partitionId, TieredStorageSubpartitionId subpartitionId, int segmentId)
TierConsumerAgentgetNextBuffer in interface TierConsumerAgentpartitionId - the id of partition.subpartitionId - the id of subpartition.segmentId - the id of segment.public void registerAvailabilityNotifier(AvailabilityNotifier notifier)
TierConsumerAgentregisterAvailabilityNotifier in interface TierConsumerAgentnotifier - to notify availability.public void close()
throws IOException
TierConsumerAgentclose in interface TierConsumerAgentIOExceptionCopyright © 2014–2023 The Apache Software Foundation. All rights reserved.