Description
The goal of this Jira is to add support for creating demand based on the existing of Divert Bindings. The idea is that if a divert binding source address matches the federated address match list and the forward address matches 1 or more queue bindings (either anycast or multicast) then we should create a remote consumers to create demand between the brokers as if there was a queue binding directly on the original address.
Note that this feature is a subset of what is provided by 5.x network of brokers with Virtual destination consumers and composite destinations as described here: https://activemq.apache.org/networks-of-brokers
There are a few use cases but a primary one is legacy JMS 1.1 clients that have not been upgraded to 2.0 (so no shared subscriptions) but you want to load balance off a topic. In this case you might create a divert to move messages from a topic to a queue so multiple consumers can load balance. If the topic is part of the federated address list then we still want those consumers to be able to get messages off the topic even though they are on a different queue because the divert exists. This makes management easier as we don't need to try and add federated queues for the load balanced queues.
As of now this feature will only be supported by federated addresses and not federated queues. This works well with multicast and addresses as queue creation (or queue bindings) create the demand for remote consumers to be created so we can simply also support divert bindings that match queue bindings. For federated queues it is consumer driven and is meant to load balance so it's not really clear if this feature really work properly for federated queues. If anything we would possibly need to add anycast support to federated addresses to support it.
This new feature will be controlled by a new flag, called enableDivertBindings that is part of the federation address policy settings. By default it will be disabled as turning it on will of course cause some extra overhead and cpu plus will cause a change in behavior of the federated address.
Attachments
Issue Links
- causes
-
ARTEMIS-2752 Federated Address DivertBindings are not properly updated on queue binding removal
- Resolved
- relates to
-
ARTEMIS-2265 Support Federated Queues and Addresses
- Closed
- links to