Skip to content
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

Jersey client connection timeout doubled when posting entity #26750

Closed
oleborup opened this issue Jun 3, 2021 · 3 comments
Closed

Jersey client connection timeout doubled when posting entity #26750

oleborup opened this issue Jun 3, 2021 · 3 comments
Labels
for: external-project For an external project and not something we can fix

Comments

@oleborup
Copy link

oleborup commented Jun 3, 2021

When using Jersey client in a Spring Boot context the connection timeout is the double of what is defined when posting an entity. In short:

client.property(ClientProperties.CONNECT_TIMEOUT, 2000);
invocationBuilder.post(null); // correct connection timeout of 2 sec
invocationBuilder.post(Entity.json(request)); // double connection timeout 4 sec

The problem started with Jersey version 2.31. This project demonstrates the issue with a minimal example: https://github.com/oleborup/jersey-client-connection-timeout

I have not been able to reproduce this in a non Spring Boot context only relying on Jersey dependencies, therefore trying to post here.

Spring Boot version: 2.5.0
Java version: OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_292-b10)

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Jun 3, 2021
@snicoll
Copy link
Member

snicoll commented Jun 3, 2021

Thanks for the sample.

I have not been able to reproduce this in a non Spring Boot context only relying on Jersey dependencies.

Can you share the sample where TimeoutTests passes without Spring Boot? Looking at the code, I don't see how spring boot is involved and we haven't been changing anything recently in that area.

@snicoll snicoll added the status: waiting-for-feedback We need additional information before we can continue label Jun 3, 2021
@oleborup
Copy link
Author

oleborup commented Jun 3, 2021

Can see my Jersey only test was on an older version 🙄 Same problem now. Sorry for disturbing. Any idea where to report this?

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Jun 3, 2021
@scottfrederick
Copy link
Contributor

The Jersey issue tracker is here: https://github.com/eclipse-ee4j/jersey/issues.

It looks like this problem has already been reported there: eclipse-ee4j/jersey#4742.

@scottfrederick scottfrederick added for: external-project For an external project and not something we can fix and removed status: feedback-provided Feedback has been provided status: waiting-for-triage An issue we've not yet triaged labels Jun 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
for: external-project For an external project and not something we can fix
Projects
None yet
Development

No branches or pull requests

4 participants