You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Ron Day <ro...@ronday.cc> on 2003/04/25 14:33:10 UTC

Failover for a Datasource.

Any comments would be appreciated:

I have a database DB_one (mySQL) out on a network that is initialized in the
struts-config file. This database is not always available. When it cannot be
initialized in the ActionServlet, I would like to initalize a local database
DB_one_local that is on the same server as my Struts application.

Where is the best place to do this, and how can it be done in a robust
manner?

Thanks for any comments

ron


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


RE: Failover for a Datasource.

Posted by Ron Day <ro...@ronday.cc>.
I'm using tomcat 4.0.2, but defining datasources in Struts.

Unfortunately the client uses mysql and the rather old tomcat 4.0.2.

R

-----Original Message-----
From: Vic Cekvenich [mailto:vc@basebeans.com]
Sent: Friday, April 25, 2003 9:09 AM
To: struts-user@jakarta.apache.org
Subject: Re: Failover for a Datasource.


Some data sources in container do this automaticlay. Check you container
docs.

.V

I do not know your situations but... pgSQL I found much faster/better
than mySQL.


Ron Day wrote:

>Any comments would be appreciated:
>
>I have a database DB_one (mySQL) out on a network that is initialized in
the
>struts-config file. This database is not always available. When it cannot
be
>initialized in the ActionServlet, I would like to initalize a local
database
>DB_one_local that is on the same server as my Struts application.
>
>Where is the best place to do this, and how can it be done in a robust
>manner?
>
>Thanks for any comments
>
>ron
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Re: Failover for a Datasource.

Posted by Vic Cekvenich <vc...@basebeans.com>.
Some data sources in container do this automaticlay. Check you container 
docs.

.V

I do not know your situations but... pgSQL I found much faster/better 
than mySQL.


Ron Day wrote:

>Any comments would be appreciated:
>
>I have a database DB_one (mySQL) out on a network that is initialized in the
>struts-config file. This database is not always available. When it cannot be
>initialized in the ActionServlet, I would like to initalize a local database
>DB_one_local that is on the same server as my Struts application.
>
>Where is the best place to do this, and how can it be done in a robust
>manner?
>
>Thanks for any comments
>
>ron
>  
>



---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


RE: Failover for a Datasource.

Posted by Ron Day <ro...@ronday.cc>.
Any comments would be appreciated:

I have a database DB_one (mySQL) out on a network that is initialized in the
struts-config file. This database is not always available. When it cannot be
initialized in the ActionServlet, I would like to initalize a local database
DB_one_local that is on the same server as my Struts application.

Where is the best place to do this, and how can it be done in a robust
manner?

Thanks for any comments

ron


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Re: Failover for a Datasource.

Posted by Mark Lowe <ma...@talk21.com>.
I had similar problems with the mysql drivers and defining the data  
source in the config.xml. The strange thing is that oracle
doesn't give me any trouble. Anyway I've started defining all that in  
web.xml as a jndi datasource and i don't get the same problem, I also  
prefer it in here to save struts config for form beans and forwards.  
You can also define a datasource in server.xml which is good if you  
want all the datasource to be available to any webapp served by a given  
container.

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource- 
examples-howto.html

cheers mark


On Venerdì, apr 25, 2003, at 13:58 Europe/London, Ron Day wrote:

>
> Any comments would be appreciated:
>
> I have a database DB_one (mySQL) out on a network that is initialized  
> in the
> struts-config file. This database is not always available. When it  
> cannot be
> initialized in the ActionServlet, I would like to initalize a local  
> database
> DB_one_local that is on the same server as my Struts application.
>
> Where is the best place to do this, and how can it be done in a robust
> manner?
>
> Thanks for any comments
>
> ron
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Failover for a Datasource.

Posted by Ron Day <ro...@ronday.cc>.
Any comments would be appreciated:

I have a database DB_one (mySQL) out on a network that is initialized in the
struts-config file. This database is not always available. When it cannot be
initialized in the ActionServlet, I would like to initalize a local database
DB_one_local that is on the same server as my Struts application.

Where is the best place to do this, and how can it be done in a robust
manner?

Thanks for any comments

ron


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org