Interface BasicMessageGroupStore
- All Known Subinterfaces:
ChannelMessageStore
,MessageGroupStore
,PriorityCapableChannelMessageStore
- All Known Implementing Classes:
AbstractBatchingMessageGroupStore
,AbstractConfigurableMongoDbMessageStore
,AbstractKeyValueMessageStore
,AbstractMessageGroupStore
,ConfigurableMongoDbMessageStore
,GemfireMessageStore
,JdbcChannelMessageStore
,JdbcMessageStore
,MongoDbChannelMessageStore
,MongoDbMessageStore
,RedisChannelMessageStore
,RedisChannelPriorityMessageStore
,RedisMessageStore
,SimpleMessageStore
public interface BasicMessageGroupStore
Defines a minimal message group store with basic capabilities.
- Since:
- 4.0
- Author:
- Gary Russell
-
Method Summary
Modifier and Type Method Description MessageGroup
addMessageToGroup(Object groupId, Message<?> message)
Store a message with an association to a group id.MessageGroup
getMessageGroup(Object groupId)
Return all Messages currently in the MessageStore that were stored usingaddMessageToGroup(Object, Message)
with this group id.int
messageGroupSize(Object groupId)
Returns the size of this MessageGroup.Message<?>
pollMessageFromGroup(Object groupId)
Polls Message from thisMessageGroup
(in FIFO style if supported by the implementation) while also removing the polledMessage
void
removeMessageGroup(Object groupId)
Remove the message group with this id.
-
Method Details
-
messageGroupSize
Returns the size of this MessageGroup.- Parameters:
groupId
- The group identifier.- Returns:
- The size.
-
getMessageGroup
Return all Messages currently in the MessageStore that were stored usingaddMessageToGroup(Object, Message)
with this group id.- Parameters:
groupId
- The group identifier.- Returns:
- A group of messages, empty if none exists for this key.
-
addMessageToGroup
Store a message with an association to a group id. This can be used to group messages together.- Parameters:
groupId
- The group id to store the message under.message
- A message.- Returns:
- The message group.
-
pollMessageFromGroup
Polls Message from thisMessageGroup
(in FIFO style if supported by the implementation) while also removing the polledMessage
- Parameters:
groupId
- The group identifier.- Returns:
- The message.
-
removeMessageGroup
Remove the message group with this id.- Parameters:
groupId
- The id of the group to remove.
-