I'm using the maven-jetty-plugin to run a Spring application. Initially the datasource was declared inside Spring. Due to external constratins, I've moved it to JNDI. The jetty-env.xml section I use for local development is:
<New id="dataSource" class="org.mortbay.jetty.plus.naming.Resource">
<Arg></Arg>
<Arg>jdbc/DataSource</Arg>
<Arg>
<New class="com.mchange.v2.c3p0.ComboPooledDataSource">
<Set name="driverClass">org.hsqldb.jdbcDriver</Set>
<Set name="jdbcUrl">jdbc:hsqldb:file:target/file.db;shutdown=true
</Set>
<Set name="user">sa</Set>
<Set name="password"></Set>
<Set name="initialPoolSize">3</Set>
<Set name="maxPoolSize">5</Set>
<Set name="numHelperThreads">2</Set>
<Set name="breakAfterAcquireFailure">true</Set>
</New>
</Arg>
</New>
Unfortunately I can't see to be able to restart the web context, since the database remains locked. Any thoughts on what I'm doing wrong here?