Bundling GlassFish v3 Prelude - XWiki (Part 1)

In previous blog posts about XWiki and GlassFish, I explained how to expose XWiki on the GlassFish v2 update center and how to deploy XWiki in a GlassFish container.

Recent XWiki and GlassFish evolution.

This was a while back and XWiki, now a GlassFish partner, has nicely moved forward to version 1.5.2 (Stable). At the same time GlassFish released an embedded API and will soon ship GlassFish v3 Prelude, a lightweight container.

Shipping XWiki and GlassFish v3 Prelude together actually makes sense. The download is much smaller (21MB) than it would have been with GlassFish v2 (65MB), but having now an embedded API for the GlassFish makes it a reasonable Jetty alternative. It can for instance be used to implement an evaluation bundle (similar to what the OpenSSO folks did: 85Mb, Java Web Start deployment included).

Simple XWiki and GlassFish packaging.

Using JavaDB this time (no need to add driver in XWiki's WEB-INF/lib directory): simply edit WEB-INF/hibernate.cfg.xml to uncomment and adjust the JavaDB section, add a sun-web.xml file with a context-root set to /xwiki and update the WAR archive (xwiki-enterprise-web-1.5.2.war in my case).

Using GlassFish v3 Prelude promoted build #25 (Sept 19th), I could easily deploy by copying the archive in the auto-deploy directory (domains/domain1/autodeploy).

This can lead to a simple ZIP archive with GlassFish v3 + XWiki 1.5.2 war sitting in the auto-deploy directory. Make sure also that you nuke the domains/domain1/.felix bundle cache to avoid OSGi bundle symbolic name issues. Unzipping, starting GlassFish and pointing to http://localhost:8080/xwiki does the job (simple enough for testing/evaluating). Startup with XWiki in the autodeploy directory takes 15 seconds on my machine. Starting with Xwiki already deployed takes 8 seconds.

To be continued...

The next step is to start using the GlassFish embedded API.

Thanks to XWiki CTO Vincent Massol for the quick turnaround answering my questions and bug reports.

Comments:

Post a Comment:
Comments are closed for this entry.
About

This blog has moved

Alexis Moussine-Pouchkine's Weblog

GlassFish - Stay Connected

Search

Archives
« avril 2014
lun.mar.mer.jeu.ven.sam.dim.
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Today
Blogroll

No bookmarks in folder

News

No bookmarks in folder