0

i want to use websocket with apache karaf or other osgi container such as "service mix, felix, ..." The problem is karaf 2.3 or 3.0 use jetty with 8.X max. And jsr 356 has implemented only with jetty 9.X. If you have a really nice example would. I resigned myself to use camel but I can not handle sessions as I want.

http://docs.oracle.com/javaee/7/tutorial/doc/websocket.htm

timactive
  • 789
  • 6
  • 27
  • This is why "packaged stack" servers like Karaf are ultimately a bad idea. While they make it easier to use the components that they thought you would want, they restrict your choice. However you should be able to deploy Jetty 9 into a "plain" OSGi Framework implementation like Felix (note that Karaf and ServiceMix are both basically just Felix plus a bunch of bundles). – Neil Bartlett Dec 02 '13 at 00:27
  • Thanks @NeilBartlett for this helping answer. Afaik the felix-http still only supports Jetty 7 so it's gonna be a hassle to create this setup by himself. At timactive it's shouldn't be to hard to find a websocket sample that works with Jetty 8. Cause that already is supported by Karaf. – Achim Nierbeck Dec 02 '13 at 07:25
  • I wasn't talking about Felix-Jetty. Plain Jetty is itself already an OSGi bundle and can be used directly in any OSGi framework. – Neil Bartlett Dec 02 '13 at 11:41
  • Neil, Achim thank for your help, Achim yes i find example with jetty 8 but pure jetty solution but i wan't use solution with jsr 356 will become a common standard in the use of websocket. – timactive Dec 02 '13 at 12:09

2 Answers2

1

I use now https://github.com/mrniko/netty-socketio It is the better solution for compatibility and integration easy in karaf, felix, equinox...

timactive
  • 789
  • 6
  • 27
0

It could be more easier if you ask the help from the apache-karaf to upgrade the jetty version to 9.x.

Willem Jiang
  • 3,291
  • 1
  • 14
  • 14