Datasource support in struts is deprecated
JNDI is the J2EE compliant way to get Datasource, it is not tomcat dependant
It only requires to declare a resource-entry in your web.xml and to use your container 
configuration to link this to a
container-managed datasource

Nico.


> This is a nice solution, but I would like to use the DataSource
> configuration in struts-config.xml.
> I noticed that there is the "ConfigHelper.getDataSource()" method to get
> the default data source, but I want to use a DataSource that I mapped with
> a key.
> By the way, the solution above is not too tied to Tomcat? What if I want
> to distribute my application? Do I have to configure Tomcat on the other
> machine?
> Ciao
> Antonio Petrelli
>
> >
> >
> >
> > -----Messaggio originale-----
> > Da: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> > Inviato: martedì 21 settembre 2004 11.11
> > A: [EMAIL PROTECTED]
> > Oggetto: Assigning a DataSource to a Business Delegate on startup
> >
> >
> > Hello there,
> > is there a way I can assign a DataSource to a singleton object (i.e. a
> > Business Delegate) on startup? I know there is the "getDataSource"
> > protected method in Action, but I have to pass the DataSource itself on
> > each call of the delegate, or I have to check whether it has been
> > already passed or not. Maybe it could be done with a plugin. In this
> > case, is there already a package that I could use? And if not, how can I
> > access to a DataSource outside the Action class? Thanks in advance Ciao
> > Antonio Petrelli
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


This message contains information that may be privileged or confidential and is the 
property of the Capgemini Group. It is intended only for the person to whom it is 
addressed. If you are not the intended recipient,  you are not authorized to read, 
print, retain, copy, disseminate,  distribute, or use this message or any part 
thereof. If you receive this  message in error, please notify the sender immediately 
and delete all  copies of this message.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to