Hi Craig,
I'm very glad to recieve an e-mail from you. I keep following your
interviews in www.theserverside.com . Well I didn't know that Struts
DataSource concept has been deprecated. I've been using Weblogic from so
many years and it's very easy to configure datasources and connection pools
in Weblogic.

Thanks,
Tarun.

On 4/2/06, Craig McClanahan <[EMAIL PROTECTED]> wrote:
>
> On 4/2/06, Tarun Reddy <[EMAIL PROTECTED]> wrote:
> >
> > Could you please try not to configure your data source in Tomcat?
> Instead
> > try to configure your datasource only in struts-config.xml file as I've
> > mentioned. It should work. Please get rid of the JNDI lookup code from
> the
> > JSP and use the getDataSource(request) method which is very intelligent
> > enough to pick up the datasource object. Just to try this approach,
> > comment
> > out the resource definitions part in Tomcat and confiure the datasource
> > exactly as I've mentioned. I was also facing some problems when I tried
> to
> > keep the "key" attribute and retrieve the DataSource object through JNDI
> > lookup. Let me know if you still face any issues.
>
>
> Tarun,
>
> Using a Struts data source, instead of JNDI, is not a good long term
> solution.  Indeed, the Struts data source implementation was deprecated in
> version 1.1 and removed in version 1.2.  Current best practice for
> configuring data sources *is* to use the JNDI capabilities of your
> container.  The only reason that Struts provided a data source
> implementation at all is that servlet containers six years ago did not
> support JNDI.  Now they do.
>
> Tomcat has pretty reasonable documentation on how to configure and use
> JNDI-based data sources.  Start at:
>
>     http://tomcat.apache.org/tomcat-5.0-doc/jndi-resources-howto.html
>
> and
>
>
>
> http://tomcat.apache.org/tomcat-5.0-doc/jndi-datasource-examples-howto.html
>
> If you still have questions, the Tomcat user mailing list is a good place
> to
> get answers.
>
>
> Thanks,
> > Tarun.
>
>
> Craig
>
>

Reply via email to