you can specify the "ranking", "prioritisation" or "order" (called different things in different places) using this:
The give the following situation:
600 : class com.day.cq.wcm.foundation.forms.impl.FormsHandlingServlet (id: 2255, property: service.ranking=600); called: 23; time: 97ms; time/call: 4217µs
0 : class com.adobe.aem.graphql.sites.ui.admin.impl.FeatureToggleFilter (id: 1373, property: none); called: 0; time: 122ms; time/call: -1µs
which is run first, the filter with 600, or the one with zero as the raking order?
a) FormsHandlingServlet fitler call FeatureToggleFilter
b) FeatureToggleFilter call FormsHandlingServlet
The documentation says:
Filter ordering is defined by the filter.order property whose default value is Integer.MAX_VALUE where smaller values have higher priority over higher values.
This would imply b), but most people think its a).
Solved! Go to Solution.
Hi @TB3dock ,
They invoked in order of their service ranking, that is lowest to highest. service ranking status can be found here: https://sling.apache.org/documentation/bundles/models.html#available-injectors
Hope that helps!
||Indication of where to place the filter in the filter chain. The higher the number the earlier in the filter chain. This value may span the whole range of integer values. Two filters with equal
Please note that the ordering is actually depending on the used Apache Sling Engine bundle version. Version older than 2.3.4 of that bundle are sorting the filters in the wrong reverse order. Make sure to run a newer version of the Sling engine to get the correct ordering (see also SLING-2920).