Considerations for Replicated Event Broker Deployments

The Solace Replication facility provides a data center redundancy and disaster recovery solution for Solace PubSub+. When Replication is implemented, Guaranteed messages that are published to Message VPNs with Replication active states at one site are automatically propagated to matching Message VPNs at a mate Replication site. Therefore, in a scenario where a serious service outage occurs for one Replication site, a service switch-over to the operational mate Replication site can be performed with minimal or no message loss.

This section provides information on special considerations if your JMS applications are to be used with event brokers using the Replication facility.

Messaging API Versions

It is strongly recommended that Replication-aware applications use release 7.1.2 or later Solace enterprise messaging APIs. These versions support automatic handling of replication failovers. When a replication failover occurs, the API properly handles any in-progress messages or transactions.

Host Lists

Applications should be configured with a host list of two addresses, one for the Guaranteed Messaging-enabled virtual router at each site. The addresses can be either IP addresses or host names.

When the application attempts to connect to a standby event broker, the connection will be rejected by the event broker. After the specified number of retries per host, the API will attempt to connect to the other host in the host list. Normally, for an application to be used with Replication, if a connection fails for one host it would be good to immediately attempt to connect to the other host before retrying the same host. Therefore, setting a connect retries per host of 1 is recommended.

Host lists should not be used if you are using an active/active Replication deployment, where clients are consuming messages from endpoints on the Replication active Message VPN or on its mate Replication standby Message VPN. For such a deployment, each consuming client should only attempt to connect to the Replication active Message VPN on one host or the Replication standby Message VPN on its mate.

Automatic Reconnects

When using a Solace messaging API’s automatic reconnect feature, it should be noted that the duration of a Replication failover will be minutes or hours because operator intervention is required for the switch‑over. Therefore, it is recommended to setting the number of reconnect retries to -1, which allows a client application to attempt to reconnect indefinitely.

For an example of how to handle Replication reconnects, see the Replication sample that is included with the Solace messaging API that you are using.