jakarta.ws.rs.client.Client HTTP connections re-use #10813
DavideRossi
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I played a bit with the default Jersey connector and with the helidon-jersey-connector, but I found no way to control the re-use of HTTP connections with Helidon MP.
Why it matters: assume a K8s deployment, say you have a replicated REST API (a service exposing a replicated deployment) you are invoking from a pod using the JAX-RS client APIs.
One of the replicas stats slowing down, so you would like to avoid having all your subsequent invocations going to that specific replica. However, given the current pooling and re-use policies, this happens, and you can't take advantage of one of the pros of load balancing: having the chance to hit a healthy replica (which you can mix with timeouts and retries, perhaps using MP's own fault tolerance support).
Is there a way to just say: don't re-use existing connections in these cases?
Notice that a way to say: stop recycling this connection (because it's associated to a slow replica) would be interesting, but it's not so straightforward to take advantage of that with
@Retry.Beta Was this translation helpful? Give feedback.
All reactions