BTW, the issue is https://issues.apache.org/jira/browse/SLING-5837.
On Fri, 15 Jul 2016 at 15:24 Radu Cotescu <r...@apache.org> wrote: > Hello, > > The current release of the Sling API > org.apache.sling.api.resource.observation.ResourceChangeListener > (org.apache.sling.api.resource.observation;version=1.0.0) specification > does not provide any kind of support for path filtering or pattern > matching. As I understand it, the future regarding Resource observation is > to switch from registering OSGi EventHandlers to registering > ResourceChangeListeners. If one concept replaces the other, then we need to > find an acceptable solution for the filtering support that EventHandlers > brought to the table [0][1]. > > The implementation I proposed [2] relied on adding support for the Glob > pattern matching provided by java.nio.file.PathMatcher (albeit I only > thought of a sub-set of it). What syntax would you prefer and why? Do we > need to support the full Glob syntax? Would a sub-set be enough? Do we want > to also support RegEx? Should we actually filter everything directly in the > ResourceChangeListener#onChange and not care about providing support for > filtering in the service's configuration? > > Thanks, > Radu > > [0] - > https://osgi.org/javadoc/r6/cmpn/org/osgi/service/event/EventHandler.html > [1] - > https://osgi.org/javadoc/r6/cmpn/org/osgi/service/event/EventConstants.html#EVENT_FILTER > [2] - > https://github.com/apache/sling/commit/4264dc16205abab300d041d15524c6d996b9d40a > > >