Package org.apache.drill.exec.rpc
Class RpcCheckedFuture<T>
java.lang.Object
com.google.common.collect.ForwardingObject
com.google.common.util.concurrent.ForwardingFuture<T>
com.google.common.util.concurrent.ForwardingListenableFuture<T>
com.google.common.util.concurrent.ForwardingListenableFuture.SimpleForwardingListenableFuture<T>
org.apache.drill.common.concurrent.AbstractCheckedFuture<T,RpcException>
org.apache.drill.exec.rpc.RpcCheckedFuture<T>
- All Implemented Interfaces:
com.google.common.util.concurrent.ListenableFuture<T>,Future<T>,CheckedFuture<T,,RpcException> DrillRpcFuture<T>
public class RpcCheckedFuture<T>
extends AbstractCheckedFuture<T,RpcException>
implements DrillRpcFuture<T>
-
Nested Class Summary
Nested classes/interfaces inherited from class com.google.common.util.concurrent.ForwardingListenableFuture
com.google.common.util.concurrent.ForwardingListenableFuture.SimpleForwardingListenableFuture<V>Nested classes/interfaces inherited from class com.google.common.util.concurrent.ForwardingFuture
com.google.common.util.concurrent.ForwardingFuture.SimpleForwardingFuture<V> -
Field Summary
Fields inherited from interface org.apache.drill.exec.rpc.DrillRpcFuture
logger -
Constructor Summary
ConstructorsConstructorDescriptionRpcCheckedFuture(com.google.common.util.concurrent.ListenableFuture<T> delegate) -
Method Summary
Modifier and TypeMethodDescriptionio.netty.buffer.ByteBufprotected RpcExceptionTranslates from anInterruptedException,CancellationExceptionorExecutionExceptionthrown bygetto an exception of typeXto be thrown bycheckedGet.voidsetBuffer(io.netty.buffer.ByteBuf buffer) Methods inherited from class org.apache.drill.common.concurrent.AbstractCheckedFuture
checkedGet, checkedGetMethods inherited from class com.google.common.util.concurrent.ForwardingListenableFuture.SimpleForwardingListenableFuture
delegateMethods inherited from class com.google.common.util.concurrent.ForwardingListenableFuture
addListenerMethods inherited from class com.google.common.util.concurrent.ForwardingFuture
cancel, get, get, isCancelled, isDoneMethods inherited from class com.google.common.collect.ForwardingObject
toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.drill.common.concurrent.CheckedFuture
checkedGet, checkedGetMethods inherited from interface com.google.common.util.concurrent.ListenableFuture
addListener
-
Constructor Details
-
RpcCheckedFuture
-
-
Method Details
-
setBuffer
public void setBuffer(io.netty.buffer.ByteBuf buffer) -
mapException
Description copied from class:AbstractCheckedFutureTranslates from anInterruptedException,CancellationExceptionorExecutionExceptionthrown bygetto an exception of typeXto be thrown bycheckedGet. Subclasses must implement this method.If
eis anInterruptedException, the callingcheckedGetmethod has already restored the interrupt after catching the exception. If an implementation ofAbstractCheckedFuture.mapException(Exception)wishes to swallow the interrupt, it can do so by callingThread.interrupted().Subclasses may choose to throw, rather than return, a subclass of
RuntimeExceptionto allow creating a CheckedFuture that throws both checked and unchecked exceptions.- Specified by:
mapExceptionin classAbstractCheckedFuture<T,RpcException>
-
getBuffer
public io.netty.buffer.ByteBuf getBuffer()- Specified by:
getBufferin interfaceDrillRpcFuture<T>
-