Hello Unfortunately, only with Pax Web 8 (used in Karaf 4.4+) we've refactored the WAB/HttpService/Whiteboard inter operation. Pax Web 8 allows mixing web elements coming from different "origins" (whiteboard registration, direct registration using HttpService or web.xml/web-fragment.xml approach from WABs).
So in Pax Web 8 you should be able to reconfigure the session cookie name and there servlets registered using Whiteboard targetting the same context (as in WAB) should use the same session configuration. Also - Pax Web 8 implements correctly the session separation mentioned in https://docs.osgi.org/specification/osgi.cmpn/7.0.0/service.http.whiteboard.html#service.http.whiteboard.servletcontext : Http Sessions are not shared amongst servlets registered with different > ServletContextHelpers. That is, HttpRequest.getSession calls must provide > different sessions per associated ServletContextHelper > So even if two whiteboard servlets are registered to the same target servlet context, but using different ServletContextHelper, they'll use different session configuration. kind regards Grzegorz Grzybek pon., 27 cze 2022 o 11:33 Richard Hierlmeier <[email protected]> napisaĆ(a): > > My application runs in Karaf 4.3.7. I have a web application that is > deployed as wab application bundle (wab). This web application changes the > session cookie name in > javax.servlet.ServletContextListener#contextInitialized(). > > In another bundle I have a servlet that is defined with HttpWhiteBoard. > The servlets from the wab and the servlets from HttpWhiteBoard have > different http sessions (because they have different session cookie names > in the ServletContext). > > Is it possible to configure the session cookie for Servlets that are > deployed via HttpWhiteBoard? > > Regards > > Richard > >
