Re: Configuring DataSources using jsp: reload context.xml?

2008-07-08 Thread Jonas Wagner
The problem is now solved, though in a somewhat unsatisfying way. I wrote my own configuration file to store information about the data sources, and now I connect to databases using DriverManager. I'm still wondering about more elegant ways to do dynamical configuration of data sources. Would it

Re: Configuring DataSources using jsp: reload context.xml?

2008-07-08 Thread Sameer Acharya
be a better and simpler option. -Sameer --- On Tue, 7/8/08, Jonas Wagner [EMAIL PROTECTED] wrote: From: Jonas Wagner [EMAIL PROTECTED] Subject: Re: Configuring DataSources using jsp: reload context.xml? To: Tomcat Users List users@tomcat.apache.org Date: Tuesday, July 8, 2008, 1:50 PM The problem

RE: Configuring DataSources using jsp: reload context.xml?

2008-07-08 Thread Jonas Wagner
Thanks Sameer for your reply! That may work for new datasources but could create a problem for existing data sources specifically if they are already being used and have pooled connections. The existing pooled connections may be in use by the applications too. Since the application connects

Re: Configuring DataSources using jsp: reload context.xml?

2008-07-08 Thread Len Popp
On Tue, Jul 8, 2008 at 08:53, Jonas Wagner [EMAIL PROTECTED] wrote: Since the application connects to its datasources using the DriverManager class, I cannot use connection pooling. That's one of the reasons I tried using JNDI for such a long time :-( I think it's possible to use DBCP

Re: Configuring DataSources using jsp: reload context.xml?

2008-07-08 Thread Konstantin Kolinko
Hi, Jonas Regarding your previous e-mails where you tried to overwrite META-INF\context.xml. Please note, that at deployment time this file is copied to /conf/Catalina/localhost/application_name.xml I think that you should either update the copy of that file and then restart Tomcat. If you

RE: Configuring DataSources using jsp: reload context.xml?

2008-07-07 Thread Jonas Wagner
Good morning, I'm still trying to figure out how I can cause tomcat to re-read JNDI resources. Here is one way I found out earlier: After further tests I found out that the server will reload JNDI data sources if all the following steps are performed: 1. Change the configuration 2. Execute

AW: Configuring DataSources using jsp: reload context.xml?

2008-07-03 Thread Jonas Wagner
Thanks Hassan for your question. Are these data sources known in advance, or can the configuration tool user come up with an arbitrary new one at any time? These data sources will be known at the time of deployment, but as they are specific for each customer, I cannot write one

Re: Configuring DataSources using jsp: reload context.xml?

2008-07-03 Thread Jonas Wagner
One more update on the problem: An update on the problem: on my development server (managed by eclipse) restarting the server _sometimes_ seems to apply the changes. I haven't found out in which cases exactly. The changes are never applied when I deploy to a production server using a .war

Configuring DataSources using jsp: reload context.xml?

2008-07-02 Thread Jonas Wagner
Hello, I'm trying to write a configuration frontend for a webapp. This application uses several data sources, and it should be possible to change the username/password/database/... using the configuration frontend. My idea was that the configuration servlet would modify the META-INF/context.xml

Re: Configuring DataSources using jsp: reload context.xml?

2008-07-02 Thread Hassan Schroeder
On Wed, Jul 2, 2008 at 8:53 AM, Jonas Wagner [EMAIL PROTECTED] wrote: I'm trying to write a configuration frontend for a webapp. This application uses several data sources, and it should be possible to change the username/password/database/... using the configuration frontend. My idea was