CustomFilter is overriding OOTB RewriteFilter

Avatar

Avatar
Validate 1
Level 2
Parvathy_C
Level 2

Likes

4 likes

Total Posts

25 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 3
Boost 1
Applaud 5
View profile

Avatar
Validate 1
Level 2
Parvathy_C
Level 2

Likes

4 likes

Total Posts

25 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 3
Boost 1
Applaud 5
View profile
Parvathy_C
Level 2

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
Coach
MVP
Arun_Patidar
MVP

Likes

1,442 likes

Total Posts

3,314 posts

Correct reply

941 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,442 likes

Total Posts

3,314 posts

Correct reply

941 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
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
Ignite 1
MVP
Ankur_Khare
MVP

Likes

159 likes

Total Posts

370 posts

Correct reply

58 solutions
Top badges earned
Ignite 1
Validate 10
Validate 1
Give Back 50
Give Back 5
View profile

Avatar
Ignite 1
MVP
Ankur_Khare
MVP

Likes

159 likes

Total Posts

370 posts

Correct reply

58 solutions
Top badges earned
Ignite 1
Validate 10
Validate 1
Give Back 50
Give Back 5
View profile
Ankur_Khare
MVP

17-11-2020

Is it possible to share ur code?