(re-sending this discussion to the mailing list after it was
accidentally private)
Am 25.04.2008 um 23:25 schrieb Ian Boston:
I am interested, not least because I use Jackrabbit in Sakai.
Is this using using the Maven OSGi plugin .... the one I see in the
base pom of jackrabbit.
And when you come to deploy, does it play nice with Tomcat.... some
OSGi protagonists say that the whole of tomcat should be inside a
OSGi package, others say the OSGi container can live happily inside
tomcat.
Have a look at Sling: http://incubator.apache.org/sling/ It is a
normal webapp, ie. you can deploy a war in a standard webapp
container. Sling comes with an OSGi framework (Apache Felix) and thus
allows installing bundles at runtime.
A normal workflow is to have a maven module with some Servlets
contained. They need some special configuration to be OSGi components
that are detected by Sling and made available as servlets for HTTP
requests. The interesting part though is that you have two maven
plugins that make life very easy: first the maven-bundle-plugin [1]
from the Felix project that creates on OSGi bundle, which is just a
normal jar with some OSGi-specific annotations in the Manifest.
And the second is the maven-sling-plugin [2] which allows you to
deploy the bundle right into the running Sling webapp and install or
update the bundle - depending on whether it was already installed.
This works very smooth. And needs no restart. This is the true OSGi
magic. You simply do that on the command line:
mvn -Dsling.url=http://localhost:8080/sling/console/ package
sling:install
Back to Shindig,
Are you intending on implementing the Shindig Rest API (0.8) on
Sling + Jackrabbit or the PeopleService etc that currently in trunk ?
My idea is to provide a patch for Shindig that does two things:
- add the maven-bundle-plugin to the pom that makes the jars OSGi
bundles
- add scr config to the shindig servlets, which are just javadoc tags
that are handled by the maven-scr-plugin [3] to create component
defintions files; this makes the servlets "visible" to Sling
That allows one to simply load the shindig jars as bundles in Sling
and the servlets are ready-to-use.
I want to store gadget-specs in the JCR. The simplest thing would be
to store the XML directly as file and make them available via Sling so
that you just have to know the right URL and the contentfetcher will
do a "local" call.
This might be improved by replacing the contentfetcher for gadgetspecs
with something that directly accesses the JCR.
Not sure about the Shindig Rest API? Is it what the servlets (those 5
that inherit InjectedServlet) provide?
And regarding the OpenSocial/PeopleService part I have to look into...
Maybe this needs to OSGi-componentized as well in order to make it
extensible by other bundles once installed in the Sling container.
Alex
[1] http://felix.apache.org/site/apache-felix-maven-bundle-plugin-bnd.html
[2] http://incubator.apache.org/sling/site/sling.html
[3] http://felix.apache.org/site/apache-felix-maven-scr-plugin.html
--
Alexander Klimetschek
[EMAIL PROTECTED]
>> Day JCR Cup 08 | Win a MacBook Pro: http://dev.day.com/ <<