Hey, Service Bus and Event Hubs both require CBS.
The redirect error is encountered if you use the IoT Hub Connection String to figure out what the backing data store's connection string is. You can bypass this dance by going to Azure Portal and copying the backing Event Hubs connection string. https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-messages-read-builtin#read-from-the-built-in-endpoint Cheers, Connie Sent from Outlook<http://aka.ms/weboutlook> ________________________________ From: Robbie Gemmell <robbie.gemm...@gmail.com> Sent: Friday, January 15, 2021 3:58 AM To: users <users@qpid.apache.org> Subject: [EXTERNAL] Re: Cannot connect to Azure IoT Hub with Qpid JMS client I see, so you can use Service Bus and Event Hubs without CBS, but if using them via IoT Hub you do need CBS. Really it seems like for IoTHub the route is using Microsofts SDK. Regardless, I see the transform example uses a link-redirection error to get the secondary server details (though obviously it doesn't then actually redirect the link). The JMS clients failover bits do handle connection-redirect errors internally, but it doesn't and won't handle link-redirects itself. I dont expect it is currently possible to ascertain the info map details from the JMSException created if one is encountered at present when creating a producer/consumer, only the error type and description, so that would also rule out doing that transform with the JMS client at present. On Thu, 14 Jan 2021 at 19:33, reifujin <conn...@microsoft.com.invalid> wrote: > > For each IoT Hub that is created, the default the [built-in > endpoint](https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdocs.microsoft.com%2Fazure%2Fiot-hub%2Fiot-hub-devguide-messages-d2c%23built-in-endpoint-as-a-routing-endpoint&data=04%7C01%7Cconniey%40microsoft.com%7C30aa446596264a9a9eb708d8b94cf342%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637463087444003230%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=Xr2ik%2FvEzefMX%2Fz10S6UiPp6W%2FWhy9AL04%2Bx4cdRFq8%3D&reserved=0) > is Event Hubs. The CBS node is required if your backing datastore for IoTHub > is Event Hubs or Service Bus. > > The CBS is is /not/ needed when you try to transform the IoT connection > string into an Event Hubs connection string. Any of the SASL mechanisms will > work with IoT Hub to get the redirect to the endpoint, but then you'll need > to authorize with the CBS node to connect to that redirected endpoint. > > Here is a sample of transforming the IoT Hub Connection String to an Event > Hubs connection string. > Transform IoT Hub Connection String > <https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FAzure%2Fazure-sdk-for-js%2Fblob%2Fmaster%2Fsdk%2Feventhub%2Fevent-hubs%2Fsamples%2Ftypescript%2Fsrc%2FiothubConnectionString.ts&data=04%7C01%7Cconniey%40microsoft.com%7C30aa446596264a9a9eb708d8b94cf342%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637463087444003230%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=7gr8WAFC0OJ566ZkTDzMad2VmDoeOAXobP0fyED%2BWhs%3D&reserved=0> > > > > -- > Sent from: > https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Fqpid.2158936.n2.nabble.com%2FApache-Qpid-users-f2158936.html&data=04%7C01%7Cconniey%40microsoft.com%7C30aa446596264a9a9eb708d8b94cf342%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637463087444003230%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=f%2Bbq45c%2FaltCavmRVQ%2F6dedSWYslU8CQ7UXdRmHikAM%3D&reserved=0 > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org > For additional commands, e-mail: users-h...@qpid.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org For additional commands, e-mail: users-h...@qpid.apache.org