Joseph,

I assume your concern is same as the one that you had mentioned here: 
http://github.com/dpp/liftweb/issues/246/find.

While this is a genuine case for the scenario you described, marking db 
driver as 'provided' has the side effect of not being included with the 
generated war (because the container would be expected to provide this).

This is fine if the application is deployed on a container using 
container managed persistence. However, if you are expecting the db 
driver to be loaded by the same classloader (context classloader) as the 
application you would be expected to provide it as part of the war (and 
therefore not in 'provided' scope).

Cheers, Indrajit


On 28/12/09 1:19 AM, joseph hirn wrote:
> I had started another thread about this being a derby issue but it's
> more related to the archetype.
>
> Still in the M8 archetype, h2 db is dependency of the project rather
> than a dependency of Jetty. It is better to have jetty declare the h2
> dep because it keeps the sample app database independent. Even if you
> are programming directly to H2 API it is better to mark provided and
> have it be provided at runtime by the system or container. The bigger
> issue I'm experiencing is that it makes Jetty also unable to survive
> hot changes to class files for me. If I change a file and compile
> while jetty is running I get this error:
>
> -------------------------------------------------------------------------------------------------------------
> org.h2.jdbc.JdbcSQLException: Database may be already in use: Locked
> by another process. Possible solutions: close all other connection(s);
> use the server mode [90020-121]
>
> $mvn -version
> Apache Maven 2.2.1 (r801777; 2009-08-06 14:16:01-0500)
> Java version: 1.6.0_16
> Java home: C:\Java\jdk1.6.0_16\jre
> Default locale: en_US, platform encoding: Cp1252
> OS name: "windows 7" version: "6.1" arch: "x86" Family: "windows"
>
> -------------------------------------------------------------------------------------------------------------
>
> This is probably because the application is spinning up the database
> and Jetty is unable to clean it out entirely due to it being outside
> the scope of a normal web application (I assume is spawns some of its
> own threads).
>
>
> By moving the dependency inside of Jetty like this I no longer have
> the issue. I've used Jetty+Maven alot and have had to do this with
> other api's, specifically Tibco RVD:
> [----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------]
> <plugin>
>      <groupId>org.mortbay.jetty</groupId>
>      <artifactId>maven-jetty-plugin</artifactId>
>    <configuration>
>      <contextPath>/</contextPath>
>      <scanIntervalSeconds>5</scanIntervalSeconds>
>    </configuration>
>
>    <dependencies>
>      <dependency>
>        <groupId>com.h2database</groupId>
>        <artifactId>h2</artifactId>
>        <version>1.2.121</version>
>      </dependency>
>    </dependencies>
>
> </plugin>
> [------------------------------------------------------------------------------------------------------------------------------------------------------------]
>
>
>
> On Dec 16, 6:36 am, Xuefeng Wu<ben...@gmail.com>  wrote:
>> anyone will add the source.jar?
>>
>>
>>
>> On Wed, Dec 16, 2009 at 3:33 AM, Jim McBeath<goo...@j.jimmc.org>  wrote:
>>> It looks like the source jars are missing from the M8 repository, at
>>> least for some of the libraries (for example,
>>> <http://scala-tools.org/repo-releases/net/liftweb/lift-util/1.1-M8/>).
>>
>>> Are these perhaps located somewhere else now?  Or do they typically
>>> get added a bit later?
>>
>>> --
>>> Jim
>>
>>> On Mon, Dec 14, 2009 at 11:37:02AM -0800, David Pollak wrote:
>>>> Date: Mon, 14 Dec 2009 11:37:02 -0800
>>>> From: David Pollak<feeder.of.the.be...@gmail.com>
>>>> To: liftweb<liftweb@googlegroups.com>
>>>> Subject: [Lift] [ANN] Lift 1.1-M8
>>
>>>>     The Lift Web Framework team is pleased to announce the lift-1.1-M8
>>> release!
>>
>>> --
>>
>>> You received this message because you are subscribed to the Google Groups
>>> "Lift" group.
>>> To post to this group, send email to lift...@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> liftweb+unsubscr...@googlegroups.com<liftweb%2bunsubscr...@googlegroups.com>
>>> .
>>> For more options, visit this group at
>>> http://groups.google.com/group/liftweb?hl=en.
>>
>> --
>> Scala中文社区:  http://groups.google.com/group/scalacn
>
> --
>
> You received this message because you are subscribed to the Google Groups 
> "Lift" group.
> To post to this group, send email to lift...@googlegroups.com.
> To unsubscribe from this group, send email to 
> liftweb+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/liftweb?hl=en.
>
>

--

You received this message because you are subscribed to the Google Groups 
"Lift" group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=en.


Reply via email to