Class CachedMessageGroupMap
- java.lang.Object
-
- org.apache.activemq.broker.region.group.CachedMessageGroupMap
-
- All Implemented Interfaces:
MessageGroupMap
public class CachedMessageGroupMap extends Object implements MessageGroupMap
A simple implementation which tracks every individual GroupID value in a LRUCache
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ConsumerId
get(String groupId)
Map<String,String>
getGroups()
int
getMaximumCacheSize()
String
getType()
void
put(String groupId, ConsumerId consumerId)
void
removeAll()
MessageGroupSet
removeConsumer(ConsumerId consumerId)
ConsumerId
removeGroup(String groupId)
void
setDestination(Destination destination)
String
toString()
-
-
-
Method Detail
-
put
public void put(String groupId, ConsumerId consumerId)
- Specified by:
put
in interfaceMessageGroupMap
-
get
public ConsumerId get(String groupId)
- Specified by:
get
in interfaceMessageGroupMap
-
removeGroup
public ConsumerId removeGroup(String groupId)
- Specified by:
removeGroup
in interfaceMessageGroupMap
-
removeConsumer
public MessageGroupSet removeConsumer(ConsumerId consumerId)
- Specified by:
removeConsumer
in interfaceMessageGroupMap
-
removeAll
public void removeAll()
- Specified by:
removeAll
in interfaceMessageGroupMap
-
getGroups
public Map<String,String> getGroups()
- Specified by:
getGroups
in interfaceMessageGroupMap
- Returns:
- a map of group names and associated consumer Id
-
getType
public String getType()
- Specified by:
getType
in interfaceMessageGroupMap
-
getMaximumCacheSize
public int getMaximumCacheSize()
-
setDestination
public void setDestination(Destination destination)
- Specified by:
setDestination
in interfaceMessageGroupMap
-
-