voldemort.server.protocol
Interface StreamRequestHandler

All Known Implementing Classes:
FetchPartitionFileStreamRequestHandler, FetchStreamRequestHandler, FullScanFetchEntriesRequestHandler, FullScanFetchKeysRequestHandler, FullScanFetchStreamRequestHandler, PartitionScanFetchEntriesRequestHandler, PartitionScanFetchKeysRequestHandler, PartitionScanFetchStreamRequestHandler, UpdatePartitionEntriesStreamRequestHandler, UpdateSlopEntriesRequestHandler

public interface StreamRequestHandler

Implements an iterator-esque streaming request handler wherein we keep executing handleRequest until it returns StreamRequestHandler.StreamRequestHandlerState.COMPLETE.


Nested Class Summary
static class StreamRequestHandler.StreamRequestDirection
           
static class StreamRequestHandler.StreamRequestHandlerState
           
 
Field Summary
static int STAT_RECORDS_INTERVAL
           
 
Method Summary
 void close(java.io.DataOutputStream outputStream)
           
 StreamRequestHandler.StreamRequestDirection getDirection()
           
 void handleError(java.io.DataOutputStream outputStream, VoldemortException e)
           
 StreamRequestHandler.StreamRequestHandlerState handleRequest(java.io.DataInputStream inputStream, java.io.DataOutputStream outputStream)
          Handles a "segment" of a streaming request.
 

Field Detail

STAT_RECORDS_INTERVAL

static final int STAT_RECORDS_INTERVAL
See Also:
Constant Field Values
Method Detail

handleRequest

StreamRequestHandler.StreamRequestHandlerState handleRequest(java.io.DataInputStream inputStream,
                                                             java.io.DataOutputStream outputStream)
                                                             throws java.io.IOException
Handles a "segment" of a streaming request.

Parameters:
inputStream -
outputStream -
Returns:
StreamRequestHandler.StreamRequestHandlerState
Throws:
java.io.IOException

close

void close(java.io.DataOutputStream outputStream)
           throws java.io.IOException
Throws:
java.io.IOException

handleError

void handleError(java.io.DataOutputStream outputStream,
                 VoldemortException e)
                 throws java.io.IOException
Throws:
java.io.IOException

getDirection

StreamRequestHandler.StreamRequestDirection getDirection()


Jay Kreps, Roshan Sumbaly, Alex Feinberg, Bhupesh Bansal, Lei Gao, Chinmay Soman, Vinoth Chandar, Zhongjie Wu