This must have to do with load but there are no warnings or errors SimpleBrokerMessageHandler - Processing DISCONNECT starts to happen above a certain number of simultaneous connections. I've tried with trace logging and I still can't see why the sessions get closed. But testing with even one less client connecting and all runs smoothly.
It's a pretty standard spring framework 4 websocket STOMP application, except I've configured reactor-spring RingBufferAsyncTaskExecutor for inbound, outbound & broker channels. I'm using a Simple Broker because at the moment I'm always only replying to the websocket session's connected client ie: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Broadcasting to 1 sessions.
This is a piece of the log everything looks normal then all the websocket sessions just disconnect, my clients automatically try reconnect and they aren't able to. Is there a limit that is set somewhere or does anyone with more experience of spring have a clue what the problem be?
DEBUG: org.springframework.messaging.simp.user.UserDestinationMessageHandler - Translated /user/loadtest-31/queue/results -> [/queue/results-user5f]
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing MESSAGE destination=/queue/results-user5f session=null payload={"serialNumber":"loadtest-31","timestamp":1417095684735,"action":"ChecksumAndFil...(truncated)
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Broadcasting to 1 sessions.
TRACE: org.springframework.messaging.simp.stomp.StompEncoder - Encoding STOMP MESSAGE, headers={contentType=[application/json], destination=[/user/queue/results], content-type=[application/json;charset=UTF-8], subscription=[sub-0], message-id=[5f-62]}.
TRACE: org.springframework.web.socket.adapter.NativeWebSocketSession - Sending TextMessage payload= MESSAGE co.., byteCount=908, last=true], StandardWebSocketSession[id=5f, uri=/xxxxxx/wscon]
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Searching methods to handle SEND /app/isenabled session=5e
TRACE: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Found 1 methods: [{[/isenabled],messageType=[MESSAGE]}]
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Invoking com.xxxxx.controller.StompController#executeCheckEnabled[2 args]
TRACE: org.springframework.messaging.handler.HandlerMethod - Resolved arguments: [Message [serialNumber=null, timestamp=0, action=IsEnabled, actionDescription=null, actionMsg=null, origin=CLIENT, destinationUrl=null], com.xxxxx.websocket.DaemonHandshakeHandler$1@5f3f9317]
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Searching methods to handle SEND /app/licfileverify session=5e
TRACE: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Found 1 methods: [{[/licfileverify],messageType=[MESSAGE]}]
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Invoking com.xxxxx.controller.StompController#executeVerify[2 args]
TRACE: org.springframework.messaging.handler.HandlerMethod - Resolved arguments: [Message [serialNumber=null, timestamp=0, action=ChecksumAndFileSize, actionDescription=null, actionMsg=null, origin=CLIENT, destinationUrl=null], com.xxxxx.websocket.DaemonHandshakeHandler$1@5f3f9317]
DEBUG: org.springframework.messaging.simp.user.UserDestinationMessageHandler - Translated /user/loadtest-23/queue/results -> [/queue/results-user5e]
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing MESSAGE destination=/queue/results-user5e session=null payload={"serialNumber":"loadtest-23","timestamp":1417095684777,"action":"ChecksumAndFil...(truncated)
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Broadcasting to 1 sessions.
TRACE: org.springframework.messaging.simp.stomp.StompEncoder - Encoding STOMP MESSAGE, headers={contentType=[application/json], destination=[/user/queue/results], content-type=[application/json;charset=UTF-8], subscription=[sub-0], message-id=[5e-63]}.
TRACE: org.springframework.web.socket.adapter.NativeWebSocketSession - Sending TextMessage payload= MESSAGE co.., byteCount=908, last=true], StandardWebSocketSession[id=5e, uri=/xxxxxx/wscon]
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Searching methods to handle SEND /app/licfileverify session=62
TRACE: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Found 1 methods: [{[/licfileverify],messageType=[MESSAGE]}]
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Invoking com.xxxxx.controller.StompController#executeVerify[2 args]
TRACE: org.springframework.messaging.handler.HandlerMethod - Resolved arguments: [Message [serialNumber=null, timestamp=0, action=ChecksumAndFileSize, actionDescription=null, actionMsg=null, origin=CLIENT, destinationUrl=null], com.xxxxx.websocket.DaemonHandshakeHandler$1@38374ae2]
DEBUG: org.springframework.messaging.simp.user.UserDestinationMessageHandler - Translated /user/loadtest-25/queue/results -> [/queue/results-user62]
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing MESSAGE destination=/queue/results-user62 session=null payload={"serialNumber":"loadtest-25","timestamp":1417095684808,"action":"ChecksumAndFil...(truncated)
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Broadcasting to 1 sessions.
TRACE: org.springframework.messaging.simp.stomp.StompEncoder - Encoding STOMP MESSAGE, headers={contentType=[application/json], destination=[/user/queue/results], content-type=[application/json;charset=UTF-8], subscription=[sub-0], message-id=[62-64]}.
TRACE: org.springframework.web.socket.adapter.NativeWebSocketSession - Sending TextMessage payload= MESSAGE co.., byteCount=908, last=true], StandardWebSocketSession[id=62, uri=/xxxxxx/wscon]
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=4f, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 4f
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=4f
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=59, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 59
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=59
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=62, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 62
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=62
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=4d, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 4d
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=4d
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=65, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 65
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=65
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=4a, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 4a
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=4a
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=47, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 47
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=47
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=58, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 58
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=58
TRACE: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - Handling TextMessage payload= -----BEGIN.., byteCount=800, last=true] in StandardWebSocketSession[id=45, uri=/xxxxxx/wscon]
TRACE: org.springframework.messaging.simp.stomp.StompDecoder - Decoded SEND {destination=[/app/licfileverify]} session=null
TRACE: org.springframework.web.socket.messaging.StompSubProtocolHandler - From client: SEND /app/licfileverify session=null
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=45, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 45
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Searching methods to handle SEND /app/licfileverify session=45
TRACE: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Found 1 methods: [{[/licfileverify],messageType=[MESSAGE]}]
DEBUG: org.springframework.messaging.simp.annotation.support.SimpAnnotationMethodMessageHandler - Invoking com.xxxxx.controller.StompController#executeVerify[2 args]
TRACE: org.springframework.messaging.handler.HandlerMethod - Resolved arguments: [Message [serialNumber=null, timestamp=0, action=ChecksumAndFileSize, actionDescription=null, actionMsg=null, origin=CLIENT, destinationUrl=null], com.xxxxx.websocket.DaemonHandshakeHandler$1@1d8deca5]
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=5a, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 5a
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=61, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 61
TRACE: org.springframework.messaging.simp.user.UserDestinationMessageHandler - No user destinations found for /user/loadtest-34/queue/results
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=45
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=5a
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=61
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=67, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 67
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=67
TRACE: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - Handling TextMessage payload= CONNECT he.., byteCount=56, last=true] in StandardWebSocketSession[id=49, uri=/xxxxxx/wscon]
TRACE: org.springframework.messaging.simp.stomp.StompDecoder - Decoded CONNECT {heart-beat=[10000,10000], accept-version=[1.1,1.0]} session=null
TRACE: org.springframework.web.socket.messaging.StompSubProtocolHandler - From client: CONNECT session=null
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=49, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 49
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing CONNECT user=loadtest-4 session=49
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - No session for GenericMessage [payload=byte[540], headers={simpMessageType=CONNECT_ACK, simpConnectMessage=GenericMessage [payload=byte[0], headers={stompCommand=CONNECT, nativeHeaders={heart-beat=[10000,10000], accept-version=[1.1,1.0]}, simpSessionAttributes={org.springframework.messaging.simp.SimpAttributes.COMPLETED=true}, simpMessageType=CONNECT, simpUser=com.xxxxx.websocket.DaemonHandshakeHandler$1@68c2e436, simpSessionId=49}], simpSessionId=49}]
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=49
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=56, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 56
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=56
DEBUG: org.springframework.web.socket.handler.LoggingWebSocketHandlerDecorator - StandardWebSocketSession[id=4c, uri=/xxxxxx/wscon] closed with CloseStatus[code=1001, reason=Shutdown]
DEBUG: org.springframework.web.socket.messaging.SubProtocolWebSocketHandler - Clearing session 4c
DEBUG: org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler - Processing DISCONNECT session=4c