You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Andy Lee <th...@gmail.com> on 2015/04/21 06:33:31 UTC

Spring MVC equivalent for OSGI webapps

I'm trying to build a webapp with Felix embedded in a war, using Spring MVC
for mapping controllers and Spring messaging/websockets.  I am _not_ using
Spring DI.

However, I'm running into issues with component scanning, because Spring
doesn't understand "bundle:" URLs. After a fair bit of googling, I've found
little to no evidence of others building webapps this way, at least not
since Spring stopped work on Spring DM.

So, how _are_ people building such apps? Are there OSGI-friendly
alternatives to Spring MVC and/or Spring Messaging?



--Andy

Re: Spring MVC equivalent for OSGI webapps

Posted by Paul Bakker <pa...@luminis.eu>.
Hi Andy,

We're using mostly client side technology (e.g. AngularJS) combined with
RESTful web services and Web Sockets. For the RESTful web services we use
Amdatu Web, which brings JAX-RS to OSGi. For Web Sockets you can either use
Atmosphere which works well in OSGi, or the WebSockets APIs available in
the latest Felix HTTP bundles.

1) Amdatu web: http://amdatu.org/components/web.html
2) Example of using Atmosphere in OSGi:
https://bitbucket.org/amdatu/amdatu-bootstrap/src/1f19e9cfed6dacd6247a3268a0c0c1b1cc0e6b95/org.amdatu.bootstrap.http/src/org/amdatu/bootstrap/ws/AtmosphereServlet.java?at=master
3) Example of Felix HTTP WebSockets:
https://github.com/paulbakker/osgi-websockets-examples

Cheers,

Paul

On Tue, Apr 21, 2015 at 6:34 AM Andy Lee <th...@gmail.com> wrote:

> I'm trying to build a webapp with Felix embedded in a war, using Spring MVC
> for mapping controllers and Spring messaging/websockets.  I am _not_ using
> Spring DI.
>
> However, I'm running into issues with component scanning, because Spring
> doesn't understand "bundle:" URLs. After a fair bit of googling, I've found
> little to no evidence of others building webapps this way, at least not
> since Spring stopped work on Spring DM.
>
> So, how _are_ people building such apps? Are there OSGI-friendly
> alternatives to Spring MVC and/or Spring Messaging?
>
>
>
> --Andy
>