[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[jetty-dev] Re: Can't find org.eclipse.jetty.plus.naming.Resource
|
Found it.
The new full name of this class is of course
org.eclipse.jetty.plus.jndi.Resource
(NOT org.eclipse.jetty.plus.naming.Resource)
But now I have another problem. My goal is to use database connection
pooling for MySQL with jetty but despite my jetty-env.xml (quoted
below) the java:comp/env context is empty. I.e. there is no connection
pool object in it.
I know jetty is reading the jetty-env.xml, because it did complain
when I referred to the org.mortbay.plus.naming package. But there
seems to be no pool set up. Checking the database log shows no
activity from jetty.
Any ideas? Anyone?
********************* jetty-env.xml ***********************
<?xml version="1.0"?>
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN"
"http://www.eclipse.org/jetty/configure.dtd">
<Configure class="org.eclipse.jetty.webapp.WebAppContext">
<New id="DataSource" class="org.eclipse.jetty.plus.jndi.Resource">
<Arg>jdbc/mydb</Arg>
<Arg>
<New class="org.apache.commons.dbcp.BasicDataSource">
<Set name="driverClassName">com.mysql.jdbc.Driver</Set>
<Set name="url">jdbc:mysql://localhost/mydb</Set>
<Set name="username">dbuser</Set>
<Set name="password">dbpass</Set>
</New>
</Arg>
</New>
</Configure>