java.lang.Object
io.smallrye.mutiny.infrastructure.Infrastructure
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceAn operator logger forMulti.log(String)andUni.log(String). -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanstatic voidstatic <I1,I2, I3, O>
Functions.Function3<I1, I2, I3, O> decorate(Functions.Function3<I1, I2, I3, O> function) static <I1,I2, I3, I4, O>
Functions.Function4<I1, I2, I3, I4, O> decorate(Functions.Function4<I1, I2, I3, I4, O> function) static <I1,I2, I3, I4, I5, O>
Functions.Function5<I1, I2, I3, I4, I5, O> decorate(Functions.Function5<I1, I2, I3, I4, I5, O> function) static <I1,I2, I3, I4, I5, I6, O>
Functions.Function6<I1, I2, I3, I4, I5, I6, O> decorate(Functions.Function6<I1, I2, I3, I4, I5, I6, O> function) static <I1,I2, I3, I4, I5, I6, I7, O>
Functions.Function7<I1, I2, I3, I4, I5, I6, I7, O> decorate(Functions.Function7<I1, I2, I3, I4, I5, I6, I7, O> function) static <I1,I2, I3, I4, I5, I6, I7, I8, O>
Functions.Function8<I1, I2, I3, I4, I5, I6, I7, I8, O> decorate(Functions.Function8<I1, I2, I3, I4, I5, I6, I7, I8, O> function) static <I1,I2, I3, I4, I5, I6, I7, I8, I9, O>
Functions.Function9<I1, I2, I3, I4, I5, I6, I7, I8, I9, O> decorate(Functions.Function9<I1, I2, I3, I4, I5, I6, I7, I8, I9, O> function) static <T1,T2, T3>
Functions.TriConsumer<T1, T2, T3> decorate(Functions.TriConsumer<T1, T2, T3> consumer) static Runnablestatic <V> Callable<V> static <T1,T2> BiConsumer <T1, T2> decorate(BiConsumer<T1, T2> consumer) static <I1,I2, O>
BiFunction<I1, I2, O> decorate(BiFunction<I1, I2, O> function) static <T> BinaryOperator<T> decorate(BinaryOperator<T> operator) static BooleanSupplierdecorate(BooleanSupplier supplier) static <T> Consumer<T> static <I,O> Function <I, O> static LongConsumerdecorate(LongConsumer consumer) static <T> Predicate<T> static <T> Supplier<T> static intGet the s buffer size (for internal usage).static intGet the xs buffer size (for internal usage).static Executorstatic ScheduledExecutorServicestatic intGet the default overflow buffer size forMultiOverflowStrategy.buffer().static voidhandleDroppedException(Throwable throwable) static voidlogFromOperator(String identifier, String event, Object value, Throwable failure) Log from an operator.static <T> Multi<T> onMultiCreation(Multi<T> instance) static <T> Flow.Subscriber<? super T> onMultiSubscription(Flow.Publisher<? extends T> instance, Flow.Subscriber<? super T> subscriber) static <T> Uni<T> onUniCreation(Uni<T> instance) static <T> UniSubscriber<? super T> onUniSubscription(Uni<T> instance, UniSubscriber<? super T> subscriber) static voidreload()static voidstatic voidstatic voidstatic voidstatic voidstatic voidstatic voidsetBufferSizeS(int size) Set the s buffer size (for internal usage).static voidsetBufferSizeXs(int size) Set the xs buffer size (for internal usage).static voidDefines a custom caller thread blocking check supplier.static voidsetCompletableFutureWrapper(UnaryOperator<CompletableFuture<?>> wrapper) static voidConfigure or reset the executors.static voidChanges the default executor, and shuts the previous executor down.static voidsetDefaultExecutor(Executor executor, boolean shutdownPrevious) Changes the default executor, and shuts the previous executor down whenshutdownPreviousistrue.static voidsetDroppedExceptionHandler(Consumer<Throwable> handler) Defines a custom dropped exception handler.static voidsetMultiOverflowDefaultBufferSize(int size) Sets the default overflow buffer size forMultiOverflowStrategy.buffer().static voidsetOperatorLogger(Infrastructure.OperatorLogger operatorLogger) Defines operator logging behavior forMulti.log(String)andUni.log(String).static <T> CompletableFuture<T> wrapCompletableFuture(CompletableFuture<T> future)
-
Method Details
-
reload
public static void reload() -
setDefaultExecutor
public static void setDefaultExecutor()Configure or reset the executors. -
setDefaultExecutor
Changes the default executor, and shuts the previous executor down.- Parameters:
s- the new executor
-
setDefaultExecutor
Changes the default executor, and shuts the previous executor down whenshutdownPreviousistrue.- Parameters:
executor- the new executorshutdownPrevious-truewhen the previous executor needs to be shut down,falseotherwise
-
getDefaultWorkerPool
-
getDefaultExecutor
-
onUniCreation
-
onMultiCreation
-
onUniSubscription
public static <T> UniSubscriber<? super T> onUniSubscription(Uni<T> instance, UniSubscriber<? super T> subscriber) -
onMultiSubscription
public static <T> Flow.Subscriber<? super T> onMultiSubscription(Flow.Publisher<? extends T> instance, Flow.Subscriber<? super T> subscriber) -
decorate
-
decorate
-
decorate
-
decorate
-
decorate
-
decorate
-
decorate
public static <I1,I2, Functions.Function3<I1,I3, O> I2, decorateI3, O> (Functions.Function3<I1, I2, I3, O> function) -
decorate
public static <I1,I2, Functions.Function4<I1,I3, I4, O> I2, decorateI3, I4, O> (Functions.Function4<I1, I2, I3, I4, O> function) -
decorate
public static <I1,I2, Functions.Function5<I1,I3, I4, I5, O> I2, decorateI3, I4, I5, O> (Functions.Function5<I1, I2, I3, I4, I5, O> function) -
decorate
public static <I1,I2, Functions.Function6<I1,I3, I4, I5, I6, O> I2, decorateI3, I4, I5, I6, O> (Functions.Function6<I1, I2, I3, I4, I5, I6, O> function) -
decorate
public static <I1,I2, Functions.Function7<I1,I3, I4, I5, I6, I7, O> I2, decorateI3, I4, I5, I6, I7, O> (Functions.Function7<I1, I2, I3, I4, I5, I6, I7, O> function) -
decorate
public static <I1,I2, Functions.Function8<I1,I3, I4, I5, I6, I7, I8, O> I2, decorateI3, I4, I5, I6, I7, I8, O> (Functions.Function8<I1, I2, I3, I4, I5, I6, I7, I8, O> function) -
decorate
public static <I1,I2, Functions.Function9<I1,I3, I4, I5, I6, I7, I8, I9, O> I2, decorateI3, I4, I5, I6, I7, I8, I9, O> (Functions.Function9<I1, I2, I3, I4, I5, I6, I7, I8, I9, O> function) -
decorate
-
decorate
-
decorate
-
decorate
public static <T1,T2, Functions.TriConsumer<T1,T3> T2, decorateT3> (Functions.TriConsumer<T1, T2, T3> consumer) -
setCompletableFutureWrapper
-
wrapCompletableFuture
-
handleDroppedException
-
setCanCallerThreadBeBlockedSupplier
Defines a custom caller thread blocking check supplier.- Parameters:
supplier- the supplier, must not benulland must not throw an exception or it will also be lost.
-
canCallerThreadBeBlocked
public static boolean canCallerThreadBeBlocked() -
setDroppedExceptionHandler
Defines a custom dropped exception handler.- Parameters:
handler- the handler, must not benulland must not throw an exception or it will also be lost.
-
reloadUniInterceptors
public static void reloadUniInterceptors() -
reloadMultiInterceptors
public static void reloadMultiInterceptors() -
reloadCallbackDecorators
public static void reloadCallbackDecorators() -
clearInterceptors
public static void clearInterceptors() -
resetDroppedExceptionHandler
public static void resetDroppedExceptionHandler() -
resetCanCallerThreadBeBlockedSupplier
public static void resetCanCallerThreadBeBlockedSupplier() -
decorate
-
decorate
-
logFromOperator
public static void logFromOperator(String identifier, String event, Object value, Throwable failure) Log from an operator.This method should never be called directly but only from
Multi.log(String)andUni.log(String).- Parameters:
identifier- the event identifierevent- the event as a stringvalue- the value, if any ornullfailure- the failure, if any ornull
-
setOperatorLogger
Defines operator logging behavior forMulti.log(String)andUni.log(String).- Parameters:
operatorLogger- the new operator logger
-
resetOperatorLogger
public static void resetOperatorLogger() -
getMultiOverflowDefaultBufferSize
public static int getMultiOverflowDefaultBufferSize()Get the default overflow buffer size forMultiOverflowStrategy.buffer().- Returns:
- the default value
-
setMultiOverflowDefaultBufferSize
public static void setMultiOverflowDefaultBufferSize(int size) Sets the default overflow buffer size forMultiOverflowStrategy.buffer().- Parameters:
size- the buffer size, must be strictly positive
-
getBufferSizeXs
public static int getBufferSizeXs()Get the xs buffer size (for internal usage).- Returns:
- the buffer size
-
setBufferSizeXs
public static void setBufferSizeXs(int size) Set the xs buffer size (for internal usage).- Parameters:
size- the buffer size
-
getBufferSizeS
public static int getBufferSizeS()Get the s buffer size (for internal usage).- Returns:
- the buffer size
-
setBufferSizeS
public static void setBufferSizeS(int size) Set the s buffer size (for internal usage).- Parameters:
size- the buffer size
-