I want to enable Geo-DR and fail-over, but don’t want to update the connection string




First published on on Apr 03, 2018



Datacenters experience downtime. We still want to ensure the data processing continue to happen event if this means from a different region or data center. Azure Event Hubs supports your geographical disaster recovery plan by enabling geo-replication of the namespace metadata in a different region. With this feature, often the customers ask a question,



My client applications need an update when a failover happens?




Let me answer this question by describing how the feature works with Azure Event Hubs. The service enables the feature by pairing a primary namespace in a region with a secondary namespace in another region. You pair both the regions using an alias. An alias is a name that you provide for your geo-disaster recovery configurations and provides a single stable Fully Qualified Domain Name (FQDN) connection string. You can use this connection string in your client applications.




In the event of disaster, the customer (you) initiates a failover to your secondary namespace. Your alias now points only to your secondary namespace. However, the connection string remains the same. This concept solves many customer scenarios. Nevertheless, what about the client applications that are currently in production and depending on your current primary namespace? We have tried to solve this problem by introducing the concept of an alternate name that is tied to your current primary namespace.



So what is an alternate name?




Azure Event Hubs lets you use your current primary namespace to be the alias name when creating a geo-pair for your disaster recovery configurations. When doing so, you have the option of providing the alternate name to identify your primary namespace.




I urge you to read the following considerations before you opt for this approach.






  1. An alternate name is simply an identifier name that you give to your primary namespace.




  2. If you provide your primary namespace to be your alias, you current primary connection string is your alias connection string as well.




  3. When you do a failover in the event of a disaster – your secondary namespace becomes your primary with the same connection string (remember, your alias connection string is same as your current existing primary connection string).




  4. This means, when you want to connect back to your old primary (to drain any data or connect for any other reasons), this is not possible with the connection string.




  5. Your alternate name now comes into consideration, as this is the only way you can access your old primary.






The following script walks you through this experience of providing an alternate name and failing over using the existing primary namespace as your alias.




Geo-Disaster Recovery requires a lot of planning and consideration as this is vital to the proper and continual functioning of your business and its needs. This blog aims to educate the considerations when enabling this feature for Azure Event Hubs. As a best practice, our recommendation would be to update your clients. This is much cleaner, even though you have the option of retaining the current connection string.




We currently support the feature for meta-data replication at namespace and in future may add the data replication as well. We would love to hear what you have to say to us. Leave us your comments/feedback.








Happy Event-ing!




Azure Event Hubs Team

Leave a Reply

Your email address will not be published. Required fields are marked *

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.