-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document default connection-pool-size for REST Clients and raise default pool size to 50 for Quarkus REST #45148
Conversation
445804e
to
d7dbe06
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unlike its position in the tree could indicate, I think this config is used for both the classic and the reactive REST Clients. So we would need to make sure this change is correct for both of them.
I managed to find that the default for the Line 92 in 35ccb2e
I managed to confirm that indeed the client is created with 20 for older quakus versions when the using <dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-rest-client-reactive</artifactId>
<version>3.6.3</version>
</dependency> But I must admit I'm quite lost here about what do you mean by both classic and reactive REST clients. Isn't the reactive client the default and isn't the reactive the client used when following this guide https://quarkus.io/guides/rest-client ? If you can gimme a pom that will use the classic rest I can check what is the actual value. |
Sorry, I forgot about this one. My point is that while you are keeping the same default for RESTEasy Classic, you are actually changing the default for RESTEasy Reactive - given they use the same config (except if I'm mistaken?). I'm fine having the same default but we need to make sure it makes sense.
|
@weltonrodrigo I thought about it a bit more and I think you're right that we should align with
@geoand do you agree with this analysis? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that makes sense
This comment has been minimized.
This comment has been minimized.
🎊 PR Preview aa638a1 has been successfully built and deployed to https://quarkus-pr-main-45148-preview.surge.sh/version/main/guides/
|
This comment has been minimized.
This comment has been minimized.
I believe you'll find this funny, but I actually though This is funny because I was both wrong and right. Wrong because I wrongly interpreted the code and misunderstood the value to be 50 and right because it seems it actually should be 50. And now this thread makes so much sense to me now. |
Comment from Guillaume: The default REST Client connection pool size for RESTEasy Classic was 50, but the one for Quarkus REST is 20. Given most of the time, the limit factor will be the responsiveness of the server, not the speed of the implementation, I think we should be conservative and keep the same values. Co-authored-by: Guillaume Smet <[email protected]>
This is actually what is required for the test to pass so I switched to an annotation to only document the behavior. Still it's better to have everything aligned between RESTEasy and Quarkus REST. I wonder if we should go through the other properties and check how aligned they are and document their values. It's a bit hard to figure out the defaults atm. |
Status for workflow
|
Status for workflow
|
Default value for
quarkus.rest-client.connection-pool-size
is 50. This is the default value set by Resteasy itself that quarkus don't override by default: https://github.com/resteasy/resteasy/blob/0ccb17086c7dfffd0d6a7970db9b147fa7a0fb5c/resteasy-client/src/main/java/org/jboss/resteasy/client/jaxrs/internal/ResteasyClientBuilderImpl.java#L62