public abstract class AbstractRequestContextAwareFuture<T> extends CompletableFuture<T>
CompletableFuture which pushing RequestContext into the thread-local
when executes callbacks.CompletableFuture.AsynchronousCompletionTask| Modifier | Constructor and Description |
|---|---|
protected |
AbstractRequestContextAwareFuture(RequestContext ctx) |
| Modifier and Type | Method and Description |
|---|---|
protected RequestContext |
ctx() |
T |
get() |
T |
get(long timeout,
TimeUnit unit) |
T |
join() |
protected <I,U> BiConsumer<I,U> |
makeContextAwareLoggingException(BiConsumer<I,U> action) |
protected <I,U,V> BiFunction<I,U,V> |
makeContextAwareLoggingException(BiFunction<I,U,V> fn) |
protected <I> Consumer<I> |
makeContextAwareLoggingException(Consumer<I> action) |
protected <I,R> Function<I,R> |
makeContextAwareLoggingException(Function<I,R> fn) |
protected Runnable |
makeContextAwareLoggingException(Runnable action) |
protected <V> Supplier<V> |
makeContextAwareLoggingException(Supplier<? extends V> supplier) |
acceptEither, acceptEitherAsync, acceptEitherAsync, allOf, anyOf, applyToEither, applyToEitherAsync, applyToEitherAsync, cancel, complete, completedFuture, completeExceptionally, exceptionally, getNow, getNumberOfDependents, handle, handleAsync, handleAsync, isCancelled, isCompletedExceptionally, isDone, obtrudeException, obtrudeValue, runAfterBoth, runAfterBothAsync, runAfterBothAsync, runAfterEither, runAfterEitherAsync, runAfterEitherAsync, runAsync, runAsync, supplyAsync, supplyAsync, thenAccept, thenAcceptAsync, thenAcceptAsync, thenAcceptBoth, thenAcceptBothAsync, thenAcceptBothAsync, thenApply, thenApplyAsync, thenApplyAsync, thenCombine, thenCombineAsync, thenCombineAsync, thenCompose, thenComposeAsync, thenComposeAsync, thenRun, thenRunAsync, thenRunAsync, toCompletableFuture, toString, whenComplete, whenCompleteAsync, whenCompleteAsyncprotected AbstractRequestContextAwareFuture(RequestContext ctx)
protected RequestContext ctx()
public T get() throws InterruptedException, ExecutionException
get in interface Future<T>get in class CompletableFuture<T>InterruptedExceptionExecutionExceptionpublic T get(long timeout, TimeUnit unit) throws InterruptedException, ExecutionException, TimeoutException
get in interface Future<T>get in class CompletableFuture<T>InterruptedExceptionExecutionExceptionTimeoutExceptionpublic T join()
join in class CompletableFuture<T>protected Runnable makeContextAwareLoggingException(Runnable action)
protected <I> Consumer<I> makeContextAwareLoggingException(Consumer<I> action)
protected <I,U> BiConsumer<I,U> makeContextAwareLoggingException(BiConsumer<I,U> action)
protected <V> Supplier<V> makeContextAwareLoggingException(Supplier<? extends V> supplier)
protected <I,R> Function<I,R> makeContextAwareLoggingException(Function<I,R> fn)
protected <I,U,V> BiFunction<I,U,V> makeContextAwareLoggingException(BiFunction<I,U,V> fn)
Copyright © 2020 LeanCloud. All rights reserved.