SseEventSource does not get the close call from server after upgrading to Quarkus 2.1.0.Final or later
See original GitHub issueDescribe the bug
I have created an application that uses a SseEventSource to consume events from a service. The service in some cases close the connection to the client. Using Quarkus 2.0.3.Final or earlier builds the client gets the disconnected and auto connect. So far so good. Upgrading to Quarkus 2.1.0.Final or later the client does not get disconnected. The client just stops receiving events. SseEventSource::isOpen is still true
Expected behavior
Client should get the close call from server and auto connect
Actual behavior
Client still think the connection is open but no events are consumed.
How to Reproduce?
The example inlcudes two projects. One for the broker and on for the subscriber.
- Run in a command prompt or terminal gradlew build in path to project/sse-broker
- Run gradlew quarkusDev in path to project/sse-broker
- Run in another command prompt gradlew build in path to project/sse-test
- Run gradlew quarkusDev in path to project/sse-test
- Observe that the log Number of events: x, connected true still counts after the connection is closed (after a minute)
- Update Quarkus version in path to project/sse-test/gradle.properties to 2.1.0.Final and restart the applications
- Now observe that the log Number of events: x, connected true stops counting after the connections is closed
Output of uname -a
or ver
No response
Output of java -version
11
GraalVM version (if different from Java)
No response
Quarkus version or git rev
2.1.0.Final
Build tool (ie. output of mvnw --version
or gradlew --version
)
Gradle 7.1
Additional information
No response
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
Using Apache Kafka with Schema Registry and Avro - Quarkus
When not running in dev or test mode, you will need to start your own Kafka broker and Apicurio Registry. The easiest way...
Read more >ScoopInstaller/Main/issues/new?title=lessmsi%401.10.0 ... - IssueHint
SseEventSource does not get the close call from server after upgrading to Quarkus 2.1.0.Final or later, 8, 2021-11-19, 2022-08-05.
Read more >How to setup cloud recording service with Microsoft Azure
SseEventSource does not get the close call from server after upgrading to Quarkus 2.1.0.Final or later, 8, 2021-11-19 ; HTTPError: Response code ...
Read more >RESTEasy is a JBoss project that provides various ...
RESTEasy is a JBoss.org project aimed at providing productivity frameworks for developing client and server RESTful applications and services in ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
https://issues.redhat.com/browse/RESTEASY-3051 has been fixed in RESTEasy 4.7.4.Final so this issue should be fixed starting with Quarkus 2.6.0.CR1.
@stuartwdouglas @johan-hanson Get it. I need to fix this with adding reconnect or close here: https://github.com/resteasy/resteasy/pull/2770/files#diff-3dd8163eff5a9534a4c0f7f98982ed905b4b5591766889e44749b4d524e19551R381. The Resteasy issue is created : https://issues.redhat.com/browse/RESTEASY-3051 I already fixed this locally and will merge to upstream soon.