dev@glassfish.java.net

Re: scattered archive support in embedded-web

From: Vivek Pandey <Vivek.Pandey_at_Sun.COM>
Date: Mon, 10 Aug 2009 16:17:44 -0700

[Taking the discussion to dev alias]

I tried running a simple servlet as scattered archive using
glassfish-embedded-web.jar. Few notes

* Jersey dependency is missing from glassfish-embedded-web.jar. This
patch fixes CNF error:

Index: /ws/v3/extras/embedded/web/pom.xml
===================================================================
--- /ws/v3/extras/embedded/web/pom.xml (revision 30287)
+++ /ws/v3/extras/embedded/web/pom.xml (working copy)
@@ -196,6 +196,12 @@
         </dependency>
         <dependency>
             <groupId>org.glassfish.packager</groupId>
+ <artifactId>jersey</artifactId>
+ <version>${project.version}</version>
+ <type>zip</type>
+ </dependency>
+ <dependency>
+ <groupId>org.glassfish.packager</groupId>
             <artifactId>glassfish-jdbc</artifactId>
             <version>${project.version}</version>
             <type>zip</type>

* Then there are couple other exceptions.

One of the NPE is present even in the test that you
mentioned(/ws/v3/distributions/web/src/test/java/org/glassfish/distributions/test/EmbeddedTest.java).
Surprisingly the test passes. Please look in to it.

See the NPE at: http://pastie.org/579259

Another exception is coming during the monitoring stats provider
registration. I am not sure what is missing from
glassfish-embedded-web.jar which is causing this failure. Can someone
from monitoring comment on it?

http://pastie.org/579261

Despite the above two exceptions, this simple application deploys fine
and is accessible. I will try a simple grails applicaiton which is full
blown Spring/Hibernate web application.

thanks,

-vivek.


Siraj Ghaffar wrote:
>
> Yes, take a look at
> /ws/v3/distributions/web/src/test/java/org/glassfish/distributions/test/EmbeddedTest.java
> for a sample on how to use the API.
>
>
>
> Vivek Pandey wrote:
>> Hi Siraj,
>>
>> I heard that scattered WAr/Archive might be working. If thats so, can
>> you tell me how do I get started on it? Any test sample?
>>
>> -vivek.
>