CustomFilter is overriding OOTB RewriteFilter | Community
Skip to main content
Level 2
Nov 17, 2020 1:08 PM UTC
Solved

CustomFilter is overriding OOTB RewriteFilter

Hi All,

We have a Custom Filter code, which crawls the Page response and replaces a text. 

This is working fine, but this code is overriding RewriteFilter class. Because of that, long-short url conversion is not happening.

If we give a higher Ranking to the Custom Filter, everything works fine. But we need to find a solution to this issue other than providing Ranking. Any pointers to this will help lot.

 

Thanks,

Parvathy

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
arunpatidar
arunpatidarAccepted solution
New Participant
Nov 17, 2020 2:47 PM UTC

If you just want to replace the content, you can use sling output rewriter

https://sling.apache.org/documentation/bundles/output-rewriting-pipelines-org-apache-sling-rewriter.html

Arun Patidar

2 replies

arunpatidar
arunpatidarAccepted solution
New Participant
Nov 17, 2020 2:47 PM UTC

If you just want to replace the content, you can use sling output rewriter

https://sling.apache.org/documentation/bundles/output-rewriting-pipelines-org-apache-sling-rewriter.html

Translate
Arun Patidar
Ankur_Khare
New Participant
Nov 17, 2020 1:16 PM UTC

Is it possible to share ur code?

Translate