Technically speaking, it would be possible to define the store-and-forward address & queue used by a cluster-connection in broker.xml. You just need to know the name of the relevant cluster-connection and the ID of the target node. The name of the relevant cluster-connection is, of course, defined in broker.xml so that's relatively easy to determine. The ID of a node is generated when the journal is first initialized and it's printed in the log when the broker starts, e.g.:
AMQ221001: Apache ActiveMQ Artemis Message Broker version 2.38.0 [127.0.0.1, nodeID=1cb9e6fa-a82b-11ef-a42b-5c80b6f32172] Assume your cluster-connection is named "my-cluster" you'd use something like this on other cluster node: <address name="$.artemis.internal.sf.my-cluster.1cb9e6fa-a82b-11ef-a42b-5c80b6f32172"> <multicast> <queue name="$.artemis.internal.sf.my-cluster.1cb9e6fa-a82b-11ef-a42b-5c80b6f32172" /> </multicast> </address> Of course, if the node IDs ever change these names would have to change as well. Justin On Thu, Nov 21, 2024 at 4:41 AM Jean-Pascal Briquet <jpdigit...@gmail.com> wrote: > Hi Alexander, > > I am currently investigating the exact same issue. > If you are interested, I have created an Artemis issue about it where you > can find my analysis of the problem: > > https://issues.apache.org/jira/browse/ARTEMIS-5086 > > I'm also curious to know if it is possible to pre-create cluster sf queues > as a workaround for this issue, it could be a good idea. > > > Regards > > Jean-Pascal > > > On Thu, Nov 21, 2024 at 10:41 AM Alexander Milovidov <milovid...@gmail.com > > > wrote: > > > Hi All! > > > > We have Artemis cluster with two primary / backups, and it worked > normally > > before. Suddenly, the cluster queue was undeployed on one of the cluster > > nodes during reload of the broker configuration. There was a log message > > with event id AMQ224077 Undeploying queue > > $.artemis.internal.sf.cluster-name.cluster-node-uuid. > > > > After this queue was undeployed, the messages which were routed to other > > cluster node were unrouted and discarded. > > > > There are no address settings like autoDeleteQueues, > > autoDeleteCreatedQueues, configDeleteQueues etc. I wonder how could this > > happen. > > The cluster queue was recreated after restart of the cluster connector. > > > > I don't know the root cause of the problem and we would like to prevent > > this situation in the future because it leads to message loss. Is it ok > to > > make cluster addresses and queues to be configuration-managed on both > > cluster nodes? > > > > ActiveMQ Artemis version is 2.37.0. > > > > -- > > Regards, > > Alexander > > >