Interface MessageHandler<T extends ChannelMessage>
- Type Parameters:
T- the expected message type
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Handler for incoming messages on a subscribed channel.
-
Method Summary
Modifier and TypeMethodDescriptionvoidhandle(MessageChannel channel, T message) Handle an incoming message.
-
Method Details
-
handle
Handle an incoming message.Implementations should be fast and non-blocking. Heavy processing should be offloaded to a separate thread.
- Parameters:
channel- the channel the message was received onmessage- the message payload
-