If a basic servlet support is enough, it is easy with OSGI, onlu one line of
code to register a new servlet dynamically:

getHttpService().registerServlet( "/myplugin", new MyPluginServlet(), null,
null);

Tutorial about OSGI HttpService :
http://www.dynamicjava.org/articles/osgi-compendium/http-service

Emmanuel

On Mon, Dec 15, 2008 at 10:39 PM, Emmanuel Venisse <
[email protected]> wrote:

> Struts2 will be based on OSGI BUT in 2.5 [1] :-(
> if we want UI plugins based on Struts2 and OSGI, we'll need to do some work
>
> [1] http://cwiki.apache.org/S2WIKI/struts-25-based-on-osgi.html
>
> Emmanuel
>
>
> On Mon, Dec 15, 2008 at 10:13 PM, Emmanuel Venisse <
> [email protected]> wrote:
>
>>
>>
>> On Mon, Dec 15, 2008 at 9:28 PM, Wendy Smoak <[email protected]> wrote:
>>
>>> On Thu, Dec 11, 2008 at 2:38 PM, Emmanuel Venisse <[email protected]>
>>> wrote:
>>>
>>> > I added this prototype, based on OSGI/Felix. It implement the
>>> specifications
>>> > written by Olivier [1] for a plugins system in Continuum.
>>> ...
>>> > I hope you'll can look at it and reply with comments.
>>> ...
>>> > [1]
>>> http://cwiki.apache.org/confluence/display/CONTINUUM/Continuum+Lifecycle
>>>
>>> Hi Emmanuel, thanks for putting this together!  I don't have much to
>>> offer by way of a review, but at least wanted to let you know that
>>> someone tried it out. :)
>>>
>>> I'm just back from SpringOne where OSGi was *everywhere*, so I'm
>>> pleased to see this as a possible direction for Continuum.
>>>
>>
>> Thanks Wendy.
>> In next weeks, I plug it step by step into the Continuum core and I'll
>> look at the same time to add dynamic struts action as plugins. With what
>> I'have seen for the moment, it would be easy to add some UI plugins with
>> basic servlets but it will be more complex with Struts2/JSP
>>
>> I'm looking at spring-osgi too so the our spring components will
>> communicate with osgi plugins.
>>
>> About plugin activators, I use actually an activator class by plugin, I'll
>> probably look at an other possibility with an xml descriptor and a generic
>> activator that will read this xml file to load the plugin as an extension
>> point
>>
>> Emmanuel
>>
>>
>>
>

Reply via email to