[ https://issues.apache.org/jira/browse/HDFS-6939?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14706503#comment-14706503 ]
Surendra Singh Lilhore commented on HDFS-6939: ---------------------------------------------- >From inotify design doc. bq. 1. Allow clients to watch events from specific directories rather than from the entirety of HDFS. We will need to decide whether undesired events should be filtered out on the NameNode or client side. I think its good to add filtering on the Namenode side. Client side user only can do filtering in his application. *Patch 001:* 1. Added *Regex* based filterting, User can pass regular expression for filtering. 2. User can watch events for perticular file, by passing file path. 3. Added two new API in *DistributedFileSystem* {noformat} public DFSInotifyEventInputStream getInotifyEventStream(InotifyFilter filter); public DFSInotifyEventInputStream getInotifyEventStream(long lastReadTxid, InotifyFilter filter) {noformat} 4. In feature we can add more filter option in *InotifyFilter* object without changing API, for example event based filtering HDFS-8933 Please review and give suggestions . > Support path-based filtering of inotify events > ---------------------------------------------- > > Key: HDFS-6939 > URL: https://issues.apache.org/jira/browse/HDFS-6939 > Project: Hadoop HDFS > Issue Type: Sub-task > Components: hdfs-client, namenode, qjm > Reporter: James Thomas > Assignee: Surendra Singh Lilhore > Attachments: HDFS-6939-001.patch > > > Users should be able to specify that they only want events involving > particular paths. -- This message was sent by Atlassian JIRA (v6.3.4#6332)