-
Notifications
You must be signed in to change notification settings - Fork 161
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
Support JSR-356 websockets with Spring Boot #3741
Conversation
Reviewed 4 of 11 files at r1. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 1 at r1 (raw file):
Missing Copyright header. Comments from Reviewable |
b1d7e4b
to
bcb8671
Compare
Review status: 3 of 6 files reviewed at latest revision, 1 unresolved discussion. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 1 at r1 (raw file): Previously, caalador wrote…
Done. Comments from Reviewable |
bcb8671
to
619e667
Compare
Reviewed 3 of 11 files at r1, 4 of 4 files at r2. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 42 at r2 (raw file):
Quoted 5 lines of code…> // ServletContainerInitializer to initialize its websocket support > // and that one might or might not have been run before this code. > // Need to bail out and let JSR356WebsocketInitializer handle it > // through its listener when the websocket support is definitely > // available.Does it mean that there might be several attempts to initialize websocket endpoint (this code and probably web container)? Is it possible to postpone somehow our initialization ( this code) when we may definitely check that there is already websocket endpoint ? E.g. please see It prevents our code execution if everything is already done automatically by the web server container. flow-tests/test-spring-common/src/main/java/com/vaadin/flow/spring/test/PushView.java, line 32 at r2 (raw file):
Quoted 11 lines of code…> add(new Paragraph("Hello")); > new Thread(() -> { > try { > Thread.sleep(100); > } catch (InterruptedException e1) { > } > ui.access(() -> { > add(new Paragraph("World")); > }); > }).start(); > }Could you please extract this into a method ? flow-tests/test-spring-common/src/test/java/com/vaadin/flow/spring/test/PushIT.java, line 17 at r2 (raw file):
Fragile code. How can we be sure that its websockets and not long-polling e.g.? Comments from Reviewable |
619e667
to
494739a
Compare
Review status: all files reviewed at latest revision, 4 unresolved discussions. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 42 at r2 (raw file): Previously, denis-anisimov (Denis) wrote…
As far as I know, this should be THE place to do it with Spring Boot and I am planning to create a Spring Boot issue about serverContainer being null here if I can reproduce it outside Flow. A flow-tests/test-spring-common/src/main/java/com/vaadin/flow/spring/test/PushView.java, line 32 at r2 (raw file): Previously, denis-anisimov (Denis) wrote…
Done. flow-tests/test-spring-common/src/test/java/com/vaadin/flow/spring/test/PushIT.java, line 17 at r2 (raw file): Previously, denis-anisimov (Denis) wrote…
Fixed and added comment about how we know it's websockets Comments from Reviewable |
Reviewed 2 of 2 files at r3. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 42 at r2 (raw file): Previously, Artur- (Artur) wrote…
Sure. If it's not possible then OK. Comments from Reviewable |
Review status: all files reviewed at latest revision, 1 unresolved discussion. Comments from Reviewable |
Review status: all files reviewed at latest revision, 2 unresolved discussions. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 42 at r2 (raw file): Previously, denis-anisimov (Denis) wrote…
But the logic here now makes no sense as the if says to bail out if serverContainer is defined... Comments from Reviewable |
Review status: all files reviewed at latest revision, 2 unresolved discussions, all commit checks successful. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 42 at r2 (raw file): Previously, Artur- (Artur) wrote…
Does The comment is not blocking anyway. Comments from Reviewable |
494739a
to
5379a09
Compare
Review status: all files reviewed at latest revision, 2 unresolved discussions. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 42 at r2 (raw file): Previously, denis-anisimov (Denis) wrote…
Yes, the spec says that the server adds its own Comments from Reviewable |
Review status: all files reviewed at latest revision, 1 unresolved discussion. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 42 at r2 (raw file): Previously, Artur- (Artur) wrote…
Alright 👍 Comments from Reviewable |
Review status: all files reviewed at latest revision, 1 unresolved discussion. flow-spring-addon/src/main/java/com/vaadin/flow/spring/VaadinWebsocketEndpointExporter.java, line 1 at r1 (raw file): Previously, Artur- (Artur) wrote…
@caalador ? Please resolve the comment Comments from Reviewable |
Reviewed 2 of 4 files at r2, 2 of 2 files at r3. Comments from Reviewable |
Review status: all files reviewed at latest revision, all discussions resolved. Comments from Reviewable |
Depends on #3740
This change is