I have a spring web application which a user can deploy on their own servers. Once the application is running, the adminstrator can set the database URL and credentials from the front end, and there is no default one set up. I do not know how to do this with spring / hibernate, as my datasource is wired in once the LocalSessionFacytoryBean is created in the initialisation of my spring container.
Share
If your application server supports it and its not to complicated for your users you could use JNDI datasources. They are configurable over the application server, however its not the same as changing them at runtime.