Class HttpClientPool
java.lang.Object
io.quarkiverse.cxf.vertx.http.client.HttpClientPool
A pool of HTTP clients so that we do not have to reconnect on every request.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionio.vertx.core.http.HttpClientIf this method returns a client that is concurrently being removed byonCertificateUpdate(CertificateUpdatedEvent)then the client may still work for one request, but will be re-created on the subsequent request.io.vertx.core.VertxgetVertx()voidonCertificateUpdate(io.quarkus.tls.CertificateUpdatedEvent event) Called upon certificate reload.
-
Constructor Details
-
HttpClientPool
@Inject public HttpClientPool(io.vertx.core.Vertx vertx)
-
-
Method Details
-
getClient
If this method returns a client that is concurrently being removed byonCertificateUpdate(CertificateUpdatedEvent)then the client may still work for one request, but will be re-created on the subsequent request.- Parameters:
spec- the caching key- Returns:
- a possibly pooled client
-
onCertificateUpdate
public void onCertificateUpdate(@Observes io.quarkus.tls.CertificateUpdatedEvent event) Called upon certificate reload. Clients having the givenHttpClientPool.ClientSpec.tlsConfigurationNamewill be removed from this pool, so that they are created anew viagetClient(ClientSpec)on the next request.- Parameters:
event- the update event
-
getVertx
public io.vertx.core.Vertx getVertx()
-