0

I'm trying to get SessionListener work with my JAX-RS JSON channel. A bit probing in the dark, I was trying to instantiate Pax-Whiteboard environment which ought to be able to process the listener, so I've added the bundles to my OSGi environment. Now I have the following error:

[Blueprint Extender: 3] ERROR org.ops4j.pax.web.extender.whiteboard.internal.WebApplication - Registration skipped for [ListenerWebElement{mapping=DefaultListenerMapping{httpContextId=null,listener=org.example.MySessionListener@5c235feb}}] due to error during registration java.lang.UnsupportedOperationException: Internal error: In use HttpService is not an WebContainer (from Pax Web)

What does this error mean? Does it mean, that Pax-processed SessionListener can't be used because Pax creates own HttpService, and I already have those that supports JAX-WS?

And more specifically, is there a way I can deal with it?

9ilsdx 9rvj 0lo
  • 7,955
  • 10
  • 38
  • 77

1 Answers1

0

Looks like you're missing some Pax-Web bundles. The OSGi HttpService Spec doesn't provide the possibility for SessionListeners, this is only possible with the new OSGi R6 Http Whiteboard specification. Depending on the version of Pax-Web you're using, this is possible or not possible. But to have this, especially for versions prior 6.0, you'll also need to add the Pax-Web-War and maybe some more bundle to your environment. Take a look at the corresponding integration tests of the Pax-Web project Pax-Web-Integrationtests base class This is a complete list of bundles needed to run Pax-Web including with War extensions, so you might need to strip of some.

Achim Nierbeck
  • 5,265
  • 2
  • 14
  • 22