Package io.quarkus.arc.spi
Interface NonBlockingProvider
public interface NonBlockingProvider
This class allows us to offload a non-blocking startup method to a non-blocking thread. This is implemented in the
Quarkus Vert.x extension.
-
Method Summary
Modifier and TypeMethodDescription<T> TsubscribeAndAwait(Supplier<io.smallrye.mutiny.Uni<T>> uniSupplier) Subscribes to the suppliedUnion a Vertx duplicated context; blocks the current thread and waits for the result.
-
Method Details
-
subscribeAndAwait
Subscribes to the suppliedUnion a Vertx duplicated context; blocks the current thread and waits for the result.If it's necessary, the CDI request context is activated during execution of the asynchronous code.
- Parameters:
uniSupplier-- Throws:
IllegalStateException- If called on an event loop thread.Throwable
-