Class StompSubscriptionEventListener
java.lang.Object
net.brabenetz.app.springstompserver.config.StompSubscriptionEventListener
- All Implemented Interfaces:
EventListener
,org.springframework.context.ApplicationListener<org.springframework.web.socket.messaging.SessionSubscribeEvent>
@Component
public class StompSubscriptionEventListener
extends Object
implements org.springframework.context.ApplicationListener<org.springframework.web.socket.messaging.SessionSubscribeEvent>
Listen on all subscriptions, and if a subscription starts with
WebSocketInitLoadConfigProperties.getDestinationPatterns()
, then directly send an
initial load from WebSocketInitLoadConfigProperties.getProxyUrl()
to the subscribed topic.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
onApplicationEvent
(org.springframework.web.socket.messaging.SessionSubscribeEvent event)
-
Constructor Details
-
StompSubscriptionEventListener
public StompSubscriptionEventListener()
-
-
Method Details
-
onApplicationEvent
public void onApplicationEvent(org.springframework.web.socket.messaging.SessionSubscribeEvent event) - Specified by:
onApplicationEvent
in interfaceorg.springframework.context.ApplicationListener<org.springframework.web.socket.messaging.SessionSubscribeEvent>
-