Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » Name jdbc is not bound in this Context
Name jdbc is not bound in this Context [message #215678] Wed, 18 June 2008 06:41 Go to next message
Eclipse User
Originally posted by: frank.niedermann.ifm.com

Hello,

we are migrating from WebSphere Developer Studio to Eclipse. I have
integrated Tomcat 5.5.26 as Server into Eclipse 3.2. If I start our
web projects in Tomcat out of Eclipse I get an exception:

Name jdbc is not bound in this Context

I can think of two reasons for that:

1. We have configured our JDBC connections with JNDI in the server.xml
located in the Tomcat directory. Eclipse does not seem to read/know
that file.

2. While deploying the projects into Tomcat (without Eclipse) we use
a deployment descriptor which defines which data source to use from the
server.xml. Eclipse also does not know about that (how should it).

In WebSphere developer studio there were ways to configure JNDI and
JDBC for projects before running them on the server. How can I do
that within Eclipse and Tomcat?

Thanks,
Frank
Re: Name jdbc is not bound in this Context [message #215687 is a reply to message #215678] Wed, 18 June 2008 07:51 Go to previous messageGo to next message
Philippe Marschall is currently offline Philippe Marschall
Messages: 120
Registered: July 2009
Senior Member
Frank Niedermann wrote:
> Hello,
>
> we are migrating from WebSphere Developer Studio to Eclipse. I have
> integrated Tomcat 5.5.26 as Server into Eclipse 3.2. If I start our
> web projects in Tomcat out of Eclipse I get an exception:
>
> Name jdbc is not bound in this Context
>
> I can think of two reasons for that:
>
> 1. We have configured our JDBC connections with JNDI in the server.xml
> located in the Tomcat directory. Eclipse does not seem to read/know
> that file.

Did you edit the file in your Tomcat installation directory or the
ServersX project in Eclipse?

Cheers
Philippe
Re: Name jdbc is not bound in this Context [message #215703 is a reply to message #215678] Wed, 18 June 2008 12:11 Go to previous messageGo to next message
Eclipse User
Originally posted by: frank.niedermann.ifm.com

Hi,

we already solved this issue with the help of Rainer Jung
from KippData.

We had to add a context.xml into the META-INF directory of
our projects containing the data sources.

It's possible to add the data sources to the server.xml used
by Eclipse, it's located under Servers/Tomcat.

Frank
Re: Name jdbc is not bound in this Context [message #215937 is a reply to message #215703] Mon, 23 June 2008 17:16 Go to previous message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
Frank Niedermann wrote:
> Hi,
>
> we already solved this issue with the help of Rainer Jung
> from KippData.
>
> We had to add a context.xml into the META-INF directory of
> our projects containing the data sources.
>
> It's possible to add the data sources to the server.xml used
> by Eclipse, it's located under Servers/Tomcat.
>
> Frank
>

Yes, you can also modify the server.xml under the Servers project in
your workspace. The main disadvantage of this approach is that that
configuration will disappear if you remove the project from that server.
Putting it in META-INF/context.xml means the configuration is a
persistent part of the project.

Cheers,
Larry
Previous Topic:Server Status refresh?
Next Topic:Eclipse not finding classes.
Goto Forum:
  


Current Time: Thu Sep 18 07:41:30 GMT 2014

Powered by FUDForum. Page generated in 0.02430 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software