CustomFilter is overriding OOTB RewriteFilter

Avatar

Avatar

Parvathy_C

Avatar

Parvathy_C

Parvathy_C

17-11-2020

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

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

Arun_Patidar

MVP

Total Posts

2.9K

Likes

1.0K

Correct Answer

831

Avatar

Arun_Patidar

MVP

Total Posts

2.9K

Likes

1.0K

Correct Answer

831
Arun_Patidar
MVP

17-11-2020

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....

Answers (1)

Answers (1)

Avatar

Avatar

Ankur_Khare

MVP

Avatar

Ankur_Khare

MVP

Ankur_Khare
MVP

17-11-2020

Is it possible to share ur code?