RetryingBlockFetcher

RetryingBlockFetcher is…​FIXME

RetryingBlockFetcher is created and immediately started when:

RetryingBlockFetcher uses a BlockFetchStarter to createAndStart when requested to start and later initiateRetry.

RetryingBlockFetcher uses outstandingBlocksIds internal registry of outstanding block IDs to fetch that is initially the block IDs to fetch when created.

At initiateRetry, RetryingBlockFetcher prints out the following INFO message to the logs (with the number of outstandingBlocksIds):

Retrying fetch ([retryCount]/[maxRetries]) for [size] outstanding blocks after [retryWaitTime] ms

RetryingBlockFetcher uses a RetryingBlockFetchListener to remove block IDs from the outstandingBlocksIds internal registry.

Creating RetryingBlockFetcher Instance

RetryingBlockFetcher takes the following when created:

Starting RetryingBlockFetcher — start Method

void start()

start simply fetchAllOutstanding.

Note

start is used when:

initiateRetry Internal Method

synchronized void initiateRetry()

initiateRetry…​FIXME

Note

initiateRetry is used when:

fetchAllOutstanding Internal Method

void fetchAllOutstanding()

fetchAllOutstanding requests BlockFetchStarter to createAndStart for the outstandingBlocksIds.

Note
fetchAllOutstanding is used when RetryingBlockFetcher is requested to start and initiateRetry.

RetryingBlockFetchListener

RetryingBlockFetchListener is a BlockFetchingListener that RetryingBlockFetcher uses to remove block IDs from the outstandingBlocksIds internal registry.

onBlockFetchSuccess Method

void onBlockFetchSuccess(String blockId, ManagedBuffer data)
Note
onBlockFetchSuccess is part of BlockFetchingListener Contract to…​FIXME.

onBlockFetchSuccess…​FIXME

onBlockFetchFailure Method

void onBlockFetchFailure(String blockId, Throwable exception)
Note
onBlockFetchFailure is part of BlockFetchingListener Contract to…​FIXME.

onBlockFetchFailure…​FIXME

results matching ""

    No results matching ""