voldemort.server.protocol.admin
Class AdminServiceRequestHandler
java.lang.Object
voldemort.server.protocol.admin.AdminServiceRequestHandler
- All Implemented Interfaces:
- RequestHandler
public class AdminServiceRequestHandler
- extends java.lang.Object
- implements RequestHandler
Protocol buffers implementation of a RequestHandler
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AdminServiceRequestHandler
public AdminServiceRequestHandler(ErrorCodeMapper errorCodeMapper,
StorageService storageService,
StoreRepository storeRepository,
MetadataStore metadataStore,
VoldemortConfig voldemortConfig,
AsyncOperationService asyncService,
Rebalancer rebalancer,
StreamStats stats)
handleRequest
public StreamRequestHandler handleRequest(java.io.DataInputStream inputStream,
java.io.DataOutputStream outputStream)
throws java.io.IOException
- Description copied from interface:
RequestHandler
- Handles the request as determined by the protocol and command provided as
input.
- Specified by:
handleRequest in interface RequestHandler
- Returns:
- StreamRequestHandler if this is the beginning of a streaming
request, null if self-contained
- Throws:
java.io.IOException
handleRebalanceStateChange
public VAdminProto.RebalanceStateChangeResponse handleRebalanceStateChange(VAdminProto.RebalanceStateChangeRequest request)
handleRebalanceNode
public VAdminProto.AsyncOperationStatusResponse handleRebalanceNode(VAdminProto.InitiateRebalanceNodeRequest request)
handleGetROCurrentVersionDir
public VAdminProto.GetROCurrentVersionDirResponse handleGetROCurrentVersionDir(VAdminProto.GetROCurrentVersionDirRequest request)
handleGetROMaxVersionDir
public VAdminProto.GetROMaxVersionDirResponse handleGetROMaxVersionDir(VAdminProto.GetROMaxVersionDirRequest request)
handleGetROStorageFormat
public VAdminProto.GetROStorageFormatResponse handleGetROStorageFormat(VAdminProto.GetROStorageFormatRequest request)
handleFailedFetch
public VAdminProto.FailedFetchStoreResponse handleFailedFetch(VAdminProto.FailedFetchStoreRequest request)
handleFetchPartitionFiles
public StreamRequestHandler handleFetchPartitionFiles(VAdminProto.FetchPartitionFilesRequest request)
handleUpdateSlopEntries
public StreamRequestHandler handleUpdateSlopEntries(VAdminProto.UpdateSlopEntriesRequest request)
handleFetchPartitionEntries
public StreamRequestHandler handleFetchPartitionEntries(VAdminProto.FetchPartitionEntriesRequest request)
handleUpdatePartitionEntries
public StreamRequestHandler handleUpdatePartitionEntries(VAdminProto.UpdatePartitionEntriesRequest request)
handleAsyncOperationList
public VAdminProto.AsyncOperationListResponse handleAsyncOperationList(VAdminProto.AsyncOperationListRequest request)
handleAsyncOperationStop
public VAdminProto.AsyncOperationStopResponse handleAsyncOperationStop(VAdminProto.AsyncOperationStopRequest request)
handleRollbackStore
public VAdminProto.RollbackStoreResponse handleRollbackStore(VAdminProto.RollbackStoreRequest request)
handleSwapStore
public VAdminProto.SwapStoreResponse handleSwapStore(VAdminProto.SwapStoreRequest request)
handleFetchStore
public VAdminProto.AsyncOperationStatusResponse handleFetchStore(VAdminProto.FetchStoreRequest request)
handleFetchAndUpdate
public VAdminProto.AsyncOperationStatusResponse handleFetchAndUpdate(VAdminProto.InitiateFetchAndUpdateRequest request)
handleAsyncStatus
public VAdminProto.AsyncOperationStatusResponse handleAsyncStatus(VAdminProto.AsyncOperationStatusRequest request)
handleDeletePartitionEntries
public VAdminProto.DeletePartitionEntriesResponse handleDeletePartitionEntries(VAdminProto.DeletePartitionEntriesRequest request)
handleUpdateMetadata
public VAdminProto.UpdateMetadataResponse handleUpdateMetadata(VAdminProto.UpdateMetadataRequest request)
handleGetMetadata
public VAdminProto.GetMetadataResponse handleGetMetadata(VAdminProto.GetMetadataRequest request)
handleTruncateEntries
public VAdminProto.TruncateEntriesResponse handleTruncateEntries(VAdminProto.TruncateEntriesRequest request)
handleDeleteStore
public VAdminProto.DeleteStoreResponse handleDeleteStore(VAdminProto.DeleteStoreRequest request)
handleAddStore
public VAdminProto.AddStoreResponse handleAddStore(VAdminProto.AddStoreRequest request)
isCompleteRequest
public boolean isCompleteRequest(java.nio.ByteBuffer buffer)
- This method is used by non-blocking code to determine if the give buffer
represents a complete request. Because the non-blocking code can by
definition not just block waiting for more data, it's possible to get
partial reads, and this identifies that case.
- Specified by:
isCompleteRequest in interface RequestHandler
- Parameters:
buffer - Buffer to check; the buffer is reset to position 0 before
calling this method and the caller must reset it after the call
returns
- Returns:
- True if the buffer holds a complete request, false otherwise
Jay Kreps, Roshan Sumbaly, Alex Feinberg, Bhupesh Bansal, Lei Gao