posted 17 years ago
Hi
I'm currently in the situation where I am writing an app for a client whose current database changes IP daily. Basically, they have 2 databases of identical structure but all their data is obtained from an import provided by another company (due to security restrictions they can't access the source database). In order to prevent the situation of having no data for a day if the import fails, they have set up the 2 databases on 2 servers which they work from. There is a separate constant database which holds the ip of the current database.
Now I am developing an app for them using Hibernate as the persistence layer but have no idea how to set it up so Hibernate is always pointing to the correct database. Does anyone have any idea how I can configure this and then reload hibernate's configuration every day (or even every hour if necessary) to point to the latest database.
Any help/ideas would be appreciated.
Thanks,
Kim