zyro23 / grails-spring-websocket

93 stars 28 forks source link

Closing session event is being logged in at ERROR level #66

Closed ChiranjibKarn closed 5 years ago

ChiranjibKarn commented 5 years ago

We are using this plugin in Grails 3.3.8 REST application. In log I can see many ERROR level log like below

ERROR o.s.w.s.m.SubProtocolWebSocketHandler - No messages received after ms. Closing EventSourceStreamingSockJsSession[id=]

ERROR o.s.w.s.m.SubProtocolWebSocketHandler - No messages received after ms. Closing XhrStreamingSockJsSession[id=]

ERROR o.s.w.s.m.SubProtocolWebSocketHandler - No messages received after ms. Closing WebSocketServerSockJsSession[id=]

Should not these logs be logged at INFO level?

zyro23 commented 5 years ago

which spring-websocket version is being used? grails-3.3.8 with grails-spring-webocket should pull in spring-websocket-4.3.18 and that should not log excessive errors

anyway, that logging is part of spring-websocket and not this plugin. if you really find an issue, it may make sense to open a corresponding spring issue.

hth

ChiranjibKarn commented 5 years ago

Am using grails-spring-websocket:2.4.1 and yes it is pulling spring-websocket-4.3.18.RELEASE, but still getting this issue.
Anyway, thank you for pointing that JIRA ticket, I will open an issue in spring-websocket issue tracker.

zyro23 commented 5 years ago

just in case you did not spot the related change yet:

https://github.com/spring-projects/spring-framework/commit/09cb7f4c310b66cdf46bdc4934eee7f0536dbee2#diff-e06394d1d8cb023d3a8ee380f468de8fL468

and that is definitively in 4.3.18:

https://github.com/spring-projects/spring-framework/blame/v4.3.18.RELEASE/spring-websocket/src/main/java/org/springframework/web/socket/messaging/SubProtocolWebSocketHandler.java#L471-L474