On Mon, 2016-08-01 at 14:44 +0200, Carsten Ziegeler wrote: > > > > On Mon, 2016-08-01 at 14:21 +0200, Carsten Ziegeler wrote: > > > > > > > > > > > > > > > Hi, > > > > > > > > On Mon, 2016-07-25 at 14:37 -0500, Carsten Ziegeler wrote: > > > > > > > > > > > > > > > Hi, > > > > > > > > > > did you have a look at the web console plugin whether your > > > > > servlet is > > > > > listed there? Maybe it is shadowed by something else. > > > > > > > > If you mean http://localhost:8080/system/console/httpservice, > > > > it's > > > > not > > > > listed there. > > > > > > > Then it's not found at all. Just to check: are you sure that your > > > test > > > is correct and the servlet is registered correctly? > > > You can check the service registry. > > > > Some dependency updates later the servlet appears in the HTTP > > service > > console. It is registered under the expected path but still not > > serving requests. > > > > Something to note - all other servlets are registered under Servlet > > Context 'org.osgi.service.http', while this one is registered under > > Servlet Context 'default'. > > > Yepp, as expected - org.osgi.service.http is the default context of > the > http service, in order to not break the http service, this context > has > precedence over the "default" context. > And as Sling is registered at "/", your servlet is never reached. > > You can either register within the context 'org.osgi.service.http' > (which only exists for the Felix implementation) or create your own > context. > One we have the Sling context, you can use that one
Right, after setting @Property(name="osgi.http.whiteboard.context.select", value="(osgi.http.whiteboard.context.name=org.osgi.service.http)") the servlet is registered. I'll not add that as IIUC it makes the registration non-portable and wait until we have a Sling context. Thanks, Robert
