[ 
https://issues.apache.org/jira/browse/NIFI-4768?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16324155#comment-16324155
 ] 

ASF GitHub Bot commented on NIFI-4768:
--------------------------------------

Github user mattyb149 commented on a diff in the pull request:

    https://github.com/apache/nifi/pull/2397#discussion_r161256398
  
    --- Diff: 
nifi-nar-bundles/nifi-extension-utils/nifi-reporting-utils/src/main/java/org/apache/nifi/reporting/util/provenance/ProvenanceEventConsumer.java
 ---
    @@ -89,16 +94,26 @@ public void setComponentTypeRegex(final String 
componentTypeRegex) {
             }
         }
     
    -    public void addTargetEventType(final ProvenanceEventType... types) {
    -        for (ProvenanceEventType type : types) {
    -            eventTypes.add(type);
    +    public void setComponentTypeRegexExclude(final String 
componentTypeRegex) {
    +        if (!StringUtils.isBlank(componentTypeRegex)) {
    +            this.componentTypeRegexExclude = 
Pattern.compile(componentTypeRegex);
             }
         }
     
    +    public void addTargetEventType(final ProvenanceEventType... types) {
    +        eventTypes.addAll(Arrays.asList(types));
    --- End diff --
    
    Nope, I think that was the original code, it only shows up as a diff here 
because I added a method before it. Will change it to use Collections for 
consistency.


> Add exclusion filters to SiteToSiteProvenanceReportingTask
> ----------------------------------------------------------
>
>                 Key: NIFI-4768
>                 URL: https://issues.apache.org/jira/browse/NIFI-4768
>             Project: Apache NiFi
>          Issue Type: Improvement
>            Reporter: Matt Burgess
>            Assignee: Matt Burgess
>
> Although the SiteToSiteProvenanceReportingTask has filters for which events, 
> components, etc. to capture, it is an inclusive filter, meaning if a filter 
> is set, only those entities' events will be sent. However it would be useful 
> to also have an exclusionary filter, in order to capture all events except a 
> few. 
> One particular use case is a sub-flow that processes provenance events, where 
> the user would not want to process provenance events generated by components 
> involved in the provenance-handling flow itself. In this fashion, for 
> example, if the sub-flow is in a process group (PG), then the user could 
> exclude the PG and the Input Port sending events to it, thereby allowing the 
> sub-flow to process all other events except those involved with the 
> provenance-handling flow itself.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to