Hi, I am trying to register a servlet for a specific resource type, overriding the SlingPostServlet, without any success so far. It works only for subsequent requests.
I have these SCR annotations: * @scr.component metatype="no" immediate="true" * @scr.service interface="javax.servlet.Servlet" * @scr.property name="sling.servlet.resourceTypes" value="wcmpp/image" * @scr.property name="sling.servlet.methods" value="POST" * @scr.property name="sling.servlet.prefix" value="0" I am using Curl during development like this: curl -F"sling:resourceType=wcmpp/image" -F"state=1" -F"title=foobar" $SAURL/test/1 Doing a subsequent post to /test/1 triggers my servlet as expected, not the SlingPostServlet. The only way I can get it to work at all for the initial post is register the servlet using an additional: @scr.property name="sling.servlet.paths" values.0="sling/servlet/default/POST" As specified, using an explicit path overrides everything else (and makes my servlet the default servlet because of the prefix 0) and is not the desired outcome. What am I missing? Any help is greatly appreciated. Thanks, Claus
