Hi

If you register an own Servlet which should be used as default servlet you can 
register it with

sling.servlet.resourceTypes=sling/servlet/default
sling.servlet.methods=GET
(if it should work only for GET requests)

If I upload a bundle with such a Servlet (call it MyServlet) in Sling 
everything seems to be fine, the GET requests are dispatched by the MyServlet. 
But after a restart of Sling it's a random luck which Servlet (the 
DefaultGetServlet or the MyServlet) will dispatch the request. Shouldn't there 
be a way to mark a Servlet as the one with higher priority. There is the 
getWeightedResources method on the ResourceCollector, but this doesn't help, 
because neither Servlet has more "weight". In my case I would like to install a 
Servlet which implements the OptingServlet and gets all requests first to 
decide if the DefaultGetServlet should handle the request or if it should be 
handled by the MyServlet itself.

best regards
mike

Reply via email to