I just used my web.xml reference:
<resource-ref>
<res-ref-name>jdbc/myDataSource</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
</resource-ref>
and while I do have a context in server.xml, I put it there for other
reasons, and it does not include a <ResourceLink> element. So it may not be
necessary.
Dennis
> -----Original Message-----
> From: Christopher Schultz [mailto:[EMAIL PROTECTED]
> Sent: Friday, November 14, 2003 11:09 AM
> To: Tomcat Users List
> Subject: Re: JNDI-lookup fails with GlobalResources
>
>
> Martin,
> >>In order to actually give it to a context, you need a resource link in
> >>server.xml:
> >>
> >> <ResourceLink name="jdbc/myDataSource"
> >> global="jdbc/myDataSourceRef"
> >> type="javax.sql.DataSource" />
> >
> >
> > So, that means, that I have to add a Context-entry to my server.xml
> > for my web app. I hoped I could do without this to make automatic
> > deployment possible, but it seems that this 2 things won't go
> > together, correct?
>
> Well, give it a try with just the reference in your web.xml, and no
> <Context> element in your server.xml. I assume you're trying to
> auto-deploy a WAR file, and don't want to modify the server.xml
> specifically for your app?
>
> Try that and see what happens.
>
> Anyone else have any other ideas?
>
> -chris
>
>
> ---------------------------------------------------------------------
> 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]