std::vector<std::string> failover_urls = {
"amqp://backup1.example.com",
"amqp://backup2.example.com"
};
proton::connection_options opts {};
proton::reconnect_options ropts {};
opts.reconnect(ropts);
ropts.failover_urls(failover_urls);
container.connect("amqp://primary.example.com", opts);
std::vector<std::string> failover_urls = {
"amqp://backup1.example.com",
"amqp://backup2.example.com"
};
proton::connection_options opts {};
proton::reconnect_options ropts {};
opts.reconnect(ropts);
ropts.failover_urls(failover_urls);
container.connect("amqp://primary.example.com", opts);
Copy to Clipboard
Copied!
Toggle word wrap
Toggle overflow