Class SimpleBrokerMessageHandler

java.lang.Object
org.springframework.messaging.simp.broker.AbstractBrokerMessageHandler
org.springframework.messaging.simp.broker.SimpleBrokerMessageHandler
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.context.ApplicationEventPublisherAware, org.springframework.context.Lifecycle, org.springframework.context.Phased, org.springframework.context.SmartLifecycle, MessageHandler

public class SimpleBrokerMessageHandler extends AbstractBrokerMessageHandler
A "simple" message broker that recognizes the message types defined in SimpMessageType, keeps track of subscriptions with the help of a SubscriptionRegistry and sends messages to subscribers.
Since:
4.0
Author:
Rossen Stoyanchev, Juergen Hoeller
  • Constructor Details

    • SimpleBrokerMessageHandler

      public SimpleBrokerMessageHandler(SubscribableChannel clientInboundChannel, MessageChannel clientOutboundChannel, SubscribableChannel brokerChannel, Collection<String> destinationPrefixes)
      Create a SimpleBrokerMessageHandler instance with the given message channels and destination prefixes.
      Parameters:
      clientInboundChannel - the channel for receiving messages from clients (e.g. WebSocket clients)
      clientOutboundChannel - the channel for sending messages to clients (e.g. WebSocket clients)
      brokerChannel - the channel for the application to send messages to the broker
      destinationPrefixes - prefixes to use to filter out messages
  • Method Details