• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

web.xml --- failover for DBs (Urgent)

 
Ranch Hand
Posts: 137
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

What is the best approach to define multiple databases and have a pointer to the one I currently want to use? I want to do this inside of the deployment descriptor.

Should I use
<resource-ref...> for the datasources and then have a <env-entry> pointing to the one i wanted to use?

I need this for failover.... They plan on a restart, so updating the <env-entry> is an option.

Or is there some standard?


Thanks in advance.
 
Ranch Hand
Posts: 582
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
According to my experience, we cannot update the value of web.xml as runtime value.
It is because the web container will read the content of web.xml only once when it is start up. web.xml file is web application configuration that is used by the web container to get information about our web application.

So if we want to change the value of web.xml, we have to restart the web container so it can retrieve new value.

Correct me if I am wrong
thanks
daniel
 
Thomas Mcfarrow
Ranch Hand
Posts: 137
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
They don't want a runtime solution. Failover will require a restart. I don't agree with it but I must follow it.

Are there standards for failover?
 
it's a teeny, tiny, wafer thin ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic