To be very flexible and move database to different servers more easily, we came up with the idea of using an alias per database. So by simply changing a DNS entry, we can route all queries to a different database server without changing the connection string or re-deployment of the respective client application.
To clarify:
Per database we would have an alias. So if the database is moved to a different server, only its DNS alias has to be changed.
For example:
- db1-alias.mydomain.com points to db1 on some random server.
- db2-alias.mydomain.com points do db2 on some other random server.
So lets say db1 was moved from server1 to server2, there is no need to change the connection string. Only the DNS alias entry has to be changed, forwarding to server2 instead of server1.
Are there any known drawbacks to this?