Hi Chetan,
You are correct, at least at present. This was part of the idea behind
exposing those services in the first place. See
https://issues.apache.org/jira/browse/SLING-1725.

Regards,
Justin

On Tue, Mar 25, 2014 at 7:24 AM, Chetan Mehrotra
<[email protected]> wrote:
> Any feedback on the proposed approach below?
>
> Chetan Mehrotra
>
>
> On Mon, Mar 24, 2014 at 4:49 PM, Chetan Mehrotra
> <[email protected]> wrote:
>> Hi,
>>
>> At times we have a requirement to extend the logic of Sling Post
>> Servlet and do some pre-processing and then continue with the default
>> behavior of PostServlet.
>>
>> For example if the POST request is modifying some content and we need
>> to change the ACL for the target path before that content gets created
>> I need a way to enhance the default logic in ModifyOperation
>>
>> For now I am dong this by
>> 1. Defining a custom operation 'my_modify'
>> 2. Implement a custom org.apache.sling.servlets.post.PostOperation
>> 3. Internall in custom PostOperation [2] I do my pre processing and then
>>    use a Service reference of default ModifyOperation
>>    (sling.post.operation=modify) and delegate to that
>> 4. The client would now use ':my_operation' as part of POST form data
>>
>> So wanted to confirm if above approach is fine or it would cause issues?
>>
>> Chetan Mehrotra

Reply via email to