-
1. Re: Message grouping: redistribute groups
jbertram Mar 4, 2015 10:01 AM (in response to dh2k7)1 of 1 people found this helpfulIs there a way to tell the LOCAL grouping handler to redistribute the groups to the newly available consumers on machine B?
Not at this time. The only way to redistribute a group is to close the consumer who is tagged with the group.
If've seen, that in 2.4.0 there is a GroupIdReaper, that removes group bindings after a given timeout. Looks like the feature I'm looking for?
I don't think so. That feature is to remove unused groups after a certain amount of time. In your use-case the groups are still in use.
-
2. Re: Message grouping: redistribute groups
dh2k7 Mar 5, 2015 5:00 AM (in response to jbertram)Not at this time. The only way to redistribute a group is to close the consumer who is tagged with the group.
So, when using message driven beans (jboss eap), there is no way?
I don't think so. That feature is to remove unused groups after a certain amount of time. In your use-case the groups are still in use.
As far, as I understand the code, the reaper task is started at fixed rate when the local grouping handler ist started. Everytime the reaper runs, it deletes all group bindings, whose timeCreated is older than a configured age.
But this creation time is fixed and says nothing about the activity of the group.
-
3. Re: Message grouping: redistribute groups
jbertram Mar 5, 2015 10:17 AM (in response to dh2k7)So, when using message driven beans (jboss eap), there is no way?
Sure there is. You can restart JBoss EAP or redeploy the MDB. There may be other admin features in EAP that would allow you to start/stop the MDB (e.g. from the CLI), but I'm not 100% sure on that.
As far, as I understand the code, the reaper task is started at fixed rate when the local grouping handler ist started. Everytime the reaper runs, it deletes all group bindings, whose timeCreated is older than a configured age.
But this creation time is fixed and says nothing about the activity of the group.
If you look at the org.hornetq.core.server.group.impl.LocalGroupingHandler.GroupIdReaper class you'll see that it explicitly checks the org.hornetq.core.server.group.impl.GroupBinding#getTimeUsed() and compares it with the group-timeout.
-
4. Re: Message grouping: redistribute groups
jbertram Mar 5, 2015 11:29 AM (in response to dh2k7)Couple of things:
- The HornetQ JCA RA doesn't have functionality equivalent to Camel's "cache level." Once the ClientSession and ClientConsumer are created they stick around essentially until the MDB is torn down.
- To be clear, the HornetQ JCA RA doesn't use the JMS API to connect. It uses the HornetQ Core API.
- I can't necessarily advocate setting a prefetch size to 1 as I don't know enough about the use-case (e.g. how many messages are actually grouped, the size of the groups, etc.).
-
5. Re: Message grouping: redistribute groups
sbrandt Mar 6, 2015 6:38 AM (in response to jbertram)Sorry, I totally got Dirks techstack wrong. I'll delete my answer as it is just confusing.