Skip to content

Tag: quarkus

Is there an elegant way to exit ClientRequestFilter?

I implemented a ClientRequestFilter. But one call of a client should not be filtered, which means if the request comes from this class (in my case the class is called TokenClient) the method should just return. Right now as you can see I check the path and if it contains /token it will return. But I would rat…

quarkus @ObservesAsync invoke Uni

What’s the best way to invoke Uni in an async observer? It would be great if I could just return Uni but unfortunately that doesn’t work. Answer As mentioned by @ladicek, you can: use a synchronous observer and block until termination use a synchronous observer and “trigger” the async …

How to programmatically declare a route in Quarkus?

As seen in the documentation, the standard way of declaring a route in Quarkus is with the @Path() annotation, like so : This will create the route GET /MyPath. However, @Path being an annotation, I have to give it constant expression. I would like to be able to declare a route with a non constant expression,…

Bring Uni event back to the caller thread

Given a subscription in a Quarkus application: If I understand correctly, processA will be executed on the caller thread (so if it is in a Verticle, it should be on a IO thread), processB and processC will be executed on the worker threads, processD will be on the caller/IO thread again. How can I make proces…