[jira] [Commented] (NIFI-8401) o.apache.nifi.controller.FlowController Failed to capture component stats for Stats History on Windows Systems

2021-04-07 Thread Nadeem (Jira)


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

Nadeem commented on NIFI-8401:
--

 

[~ERD] The issue is related to what [~mattyb149] has reported already NIFI-8400

Hopefully, will be fixed in 1.14.0. Thanks for the issue.

> o.apache.nifi.controller.FlowController Failed to capture component stats for 
> Stats History on Windows Systems
> --
>
> Key: NIFI-8401
> URL: https://issues.apache.org/jira/browse/NIFI-8401
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Configuration
>Affects Versions: 1.13.2
> Environment: Windows 10
> Windows Server 2019
>Reporter: Eric Detwiler
>Priority: Major
>
> 1.13.2 on Windows systems does not capture stats for Stats History by 
> default.  Error log below:
> Also located issue mentioned in post from March 2021.
> https://community.cloudera.com/t5/Support-Questions/ERROR-FlowController-Failed-to-capture-component-stats-for/td-p/312486
> Status History as a result does not function.
>  
> 2021-04-02 07:56:00,013 INFO [pool-20-thread-1] 
> o.a.n.c.r.WriteAheadFlowFileRepository Initiating checkpoint of FlowFile 
> Repository
> 2021-04-02 07:56:00,014 INFO [pool-20-thread-1] 
> o.a.n.c.r.WriteAheadFlowFileRepository Successfully checkpointed FlowFile 
> Repository with 0 records in 0 milliseconds
> 2021-04-02 07:56:17,311 ERROR [Timer-Driven Process Thread-7] 
> o.apache.nifi.controller.FlowController Failed to capture component stats for 
> Stats History
> java.lang.NullPointerException: null
>  at 
> org.apache.nifi.diagnostics.SystemDiagnostics.getOpenFileHandles(SystemDiagnostics.java:224)
>  at 
> org.apache.nifi.controller.FlowController.getNodeStatusSnapshot(FlowController.java:3011)
>  at 
> org.apache.nifi.controller.FlowController.access$400(FlowController.java:230)
>  at org.apache.nifi.controller.FlowController$2.run(FlowController.java:697)
>  at org.apache.nifi.engine.FlowEngine$2.run(FlowEngine.java:110)
>  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
>  at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
>  at 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
>  at 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
>  at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
>  at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
>  at java.lang.Thread.run(Thread.java:748)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (NIFI-8394) Fix NPE error when NiFi connects to external zookeeper insecurely

2021-04-07 Thread Joey Frazee (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8394?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Joey Frazee updated NIFI-8394:
--
Resolution: Fixed
Status: Resolved  (was: Patch Available)

> Fix NPE error when NiFi connects to external zookeeper insecurely
> -
>
> Key: NIFI-8394
> URL: https://issues.apache.org/jira/browse/NIFI-8394
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Affects Versions: 1.13.0, 1.13.1, 1.13.2
>Reporter: Nadeem
>Assignee: Nadeem
>Priority: Minor
>  Labels: zookeeper
> Fix For: 1.14.0
>
>  Time Spent: 40m
>  Remaining Estimate: 0h
>
> When NiFi connects to external zookeeper insecurely, then following error is 
> logged due to null watcher passed in zookeeper constructor. This error is 
> introduced due to changes made for adding zookeeper client with TLS NIFI-7819
> {noformat}
> ERROR [Framework Task Thread Thread-3-EventThread] 
> org.apache.zookeeper.ClientCnxn Error while calling watcher
> java.lang.NullPointerException: null
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.processEvent(ClientCnxn.java:535)
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.run(ClientCnxn.java:510)
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (NIFI-8394) Fix NPE error when NiFi connects to external zookeeper insecurely

2021-04-07 Thread Joey Frazee (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8394?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Joey Frazee updated NIFI-8394:
--
Priority: Minor  (was: Major)

> Fix NPE error when NiFi connects to external zookeeper insecurely
> -
>
> Key: NIFI-8394
> URL: https://issues.apache.org/jira/browse/NIFI-8394
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Affects Versions: 1.13.0, 1.13.1, 1.13.2
>Reporter: Nadeem
>Assignee: Nadeem
>Priority: Minor
>  Labels: zookeeper
>  Time Spent: 40m
>  Remaining Estimate: 0h
>
> When NiFi connects to external zookeeper insecurely, then following error is 
> logged due to null watcher passed in zookeeper constructor. This error is 
> introduced due to changes made for adding zookeeper client with TLS NIFI-7819
> {noformat}
> ERROR [Framework Task Thread Thread-3-EventThread] 
> org.apache.zookeeper.ClientCnxn Error while calling watcher
> java.lang.NullPointerException: null
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.processEvent(ClientCnxn.java:535)
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.run(ClientCnxn.java:510)
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (NIFI-8394) Fix NPE error when NiFi connects to external zookeeper insecurely

2021-04-07 Thread Joey Frazee (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8394?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Joey Frazee updated NIFI-8394:
--
Fix Version/s: 1.14.0

> Fix NPE error when NiFi connects to external zookeeper insecurely
> -
>
> Key: NIFI-8394
> URL: https://issues.apache.org/jira/browse/NIFI-8394
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Affects Versions: 1.13.0, 1.13.1, 1.13.2
>Reporter: Nadeem
>Assignee: Nadeem
>Priority: Minor
>  Labels: zookeeper
> Fix For: 1.14.0
>
>  Time Spent: 40m
>  Remaining Estimate: 0h
>
> When NiFi connects to external zookeeper insecurely, then following error is 
> logged due to null watcher passed in zookeeper constructor. This error is 
> introduced due to changes made for adding zookeeper client with TLS NIFI-7819
> {noformat}
> ERROR [Framework Task Thread Thread-3-EventThread] 
> org.apache.zookeeper.ClientCnxn Error while calling watcher
> java.lang.NullPointerException: null
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.processEvent(ClientCnxn.java:535)
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.run(ClientCnxn.java:510)
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (NIFI-8394) Fix NPE error when NiFi connects to external zookeeper insecurely

2021-04-07 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on NIFI-8394:
---

Commit 77a73a603b9cb27bda31118c44b13dda2489526c in nifi's branch 
refs/heads/main from Mohammed Nadeem
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=77a73a6 ]

NIFI-8394 Fix NPE error when NiFi connects to external zookeeper insecurely

This closes #4974

Signed-off-by: Joey Frazee 


> Fix NPE error when NiFi connects to external zookeeper insecurely
> -
>
> Key: NIFI-8394
> URL: https://issues.apache.org/jira/browse/NIFI-8394
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Affects Versions: 1.13.0, 1.13.1, 1.13.2
>Reporter: Nadeem
>Assignee: Nadeem
>Priority: Major
>  Labels: zookeeper
>  Time Spent: 40m
>  Remaining Estimate: 0h
>
> When NiFi connects to external zookeeper insecurely, then following error is 
> logged due to null watcher passed in zookeeper constructor. This error is 
> introduced due to changes made for adding zookeeper client with TLS NIFI-7819
> {noformat}
> ERROR [Framework Task Thread Thread-3-EventThread] 
> org.apache.zookeeper.ClientCnxn Error while calling watcher
> java.lang.NullPointerException: null
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.processEvent(ClientCnxn.java:535)
> at 
> org.apache.zookeeper.ClientCnxn$EventThread.run(ClientCnxn.java:510)
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] jfrazee closed pull request #4974: NIFI-8394: Fix NPE error when NiFi connects to external zookeeper insecurely

2021-04-07 Thread GitBox


jfrazee closed pull request #4974:
URL: https://github.com/apache/nifi/pull/4974


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Created] (NIFI-8401) o.apache.nifi.controller.FlowController Failed to capture component stats for Stats History on Windows Systems

2021-04-07 Thread Eric Detwiler (Jira)
Eric Detwiler created NIFI-8401:
---

 Summary: o.apache.nifi.controller.FlowController Failed to capture 
component stats for Stats History on Windows Systems
 Key: NIFI-8401
 URL: https://issues.apache.org/jira/browse/NIFI-8401
 Project: Apache NiFi
  Issue Type: Bug
  Components: Configuration
Affects Versions: 1.13.2
 Environment: Windows 10
Windows Server 2019
Reporter: Eric Detwiler


1.13.2 on Windows systems does not capture stats for Stats History by default.  
Error log below:

Also located issue mentioned in post from March 2021.

https://community.cloudera.com/t5/Support-Questions/ERROR-FlowController-Failed-to-capture-component-stats-for/td-p/312486

Status History as a result does not function.

 

2021-04-02 07:56:00,013 INFO [pool-20-thread-1] 
o.a.n.c.r.WriteAheadFlowFileRepository Initiating checkpoint of FlowFile 
Repository
2021-04-02 07:56:00,014 INFO [pool-20-thread-1] 
o.a.n.c.r.WriteAheadFlowFileRepository Successfully checkpointed FlowFile 
Repository with 0 records in 0 milliseconds
2021-04-02 07:56:17,311 ERROR [Timer-Driven Process Thread-7] 
o.apache.nifi.controller.FlowController Failed to capture component stats for 
Stats History
java.lang.NullPointerException: null
 at 
org.apache.nifi.diagnostics.SystemDiagnostics.getOpenFileHandles(SystemDiagnostics.java:224)
 at 
org.apache.nifi.controller.FlowController.getNodeStatusSnapshot(FlowController.java:3011)
 at 
org.apache.nifi.controller.FlowController.access$400(FlowController.java:230)
 at org.apache.nifi.controller.FlowController$2.run(FlowController.java:697)
 at org.apache.nifi.engine.FlowEngine$2.run(FlowEngine.java:110)
 at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
 at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
 at 
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
 at 
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
 at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
 at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
 at java.lang.Thread.run(Thread.java:748)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] exceptionfactory commented on a change in pull request #4981: NIFI-7198: Adding optional SSL Context Service to RedisConnectionPool…

2021-04-07 Thread GitBox


exceptionfactory commented on a change in pull request #4981:
URL: https://github.com/apache/nifi/pull/4981#discussion_r608949849



##
File path: 
nifi-nar-bundles/nifi-redis-bundle/nifi-redis-extensions/src/test/java/org/apache/nifi/redis/service/TestRedisConnectionPoolService.java
##
@@ -39,6 +47,71 @@ public void setup() throws InitializationException {
 testRunner.addControllerService("redis-service", redisService);
 }
 
+@Test
+public void testSSLContextService() throws InitializationException {
+StandardRestrictedSSLContextService sslContextService = new 
StandardRestrictedSSLContextService();
+testRunner.addControllerService("ssl-context-service", 
sslContextService);
+testRunner.setProperty(sslContextService, 
StandardSSLContextService.TRUSTSTORE, "src/test/resources/truststore.jks");
+testRunner.setProperty(sslContextService, 
StandardSSLContextService.TRUSTSTORE_PASSWORD, "passwordpassword");
+testRunner.setProperty(sslContextService, 
StandardSSLContextService.TRUSTSTORE_TYPE, "JKS");
+testRunner.setProperty(sslContextService, 
StandardSSLContextService.KEYSTORE, "src/test/resources/keystore.jks");
+testRunner.setProperty(sslContextService, 
StandardSSLContextService.KEYSTORE_PASSWORD, "passwordpassword");
+testRunner.setProperty(sslContextService, 
StandardSSLContextService.KEYSTORE_TYPE, "JKS");
+testRunner.setProperty(sslContextService, 
StandardSSLContextService.SSL_ALGORITHM, TlsConfiguration.TLS_1_2_PROTOCOL);

Review comment:
   Rather than creating an instance of `RestrictedSSLContextService`, 
recommend mocking the interface and return a mocked `SSLContext`.  This avoids 
the test dependency on the `nifi-ssl-context-service` library and also avoids 
checking committing additional binary keystore and truststore files.  See other 
components for examples of mocking the `RestrictedSSLContextService` interface 
for testing.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Updated] (NIFI-7198) Support TLS in RedisConnectionPoolService

2021-04-07 Thread Joseph Gresock (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-7198?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Joseph Gresock updated NIFI-7198:
-
Fix Version/s: 1.14.0
   Status: Patch Available  (was: In Progress)

> Support TLS in RedisConnectionPoolService
> -
>
> Key: NIFI-7198
> URL: https://issues.apache.org/jira/browse/NIFI-7198
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Affects Versions: 1.11.3
>Reporter: David
>Assignee: Joseph Gresock
>Priority: Minor
>  Labels: Security, TLS
> Fix For: 1.14.0
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> Redis now supports a TLS configuration ([https://redis.io/topics/encryption)]
> I would like to make use of Redis as a DistrubutedMapCache provider, but our 
> environment requires all traffic be TLS encrypted and the 
> RedisConnectionPoolService does not support TLS.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] gresockj opened a new pull request #4981: NIFI-7198: Adding optional SSL Context Service to RedisConnectionPool…

2021-04-07 Thread GitBox


gresockj opened a new pull request #4981:
URL: https://github.com/apache/nifi/pull/4981


   …Service
   
    Description of PR
   
   This adds an optional property "SSL Context Service" to the 
RedisConnectionPoolService, which allows users to connect to a TLS-secured 
Redis port.
   
   In order to streamline the review of the contribution we ask you
   to ensure the following steps have been taken:
   
   ### For all changes:
   - [x] Is there a JIRA ticket associated with this PR? Is it referenced 
in the commit message?
   
   - [x] Does your PR title start with **NIFI-** where  is the JIRA 
number you are trying to resolve? Pay particular attention to the hyphen "-" 
character.
   
   - [x] Has your PR been rebased against the latest commit within the target 
branch (typically `main`)?
   
   - [x] Is your initial contribution a single, squashed commit? _Additional 
commits in response to PR reviewer feedback should be made on this branch and 
pushed to allow change tracking. Do not `squash` or use `--force` when pushing 
to allow for clean monitoring of changes._
   
   ### For code changes:
   - [x] Have you ensured that the full suite of tests is executed via `mvn 
-Pcontrib-check clean install` at the root `nifi` folder?
   - [x] Have you written or updated unit tests to verify your changes?
   - [x] Have you verified that the full build is successful on JDK 8?
   - [x] Have you verified that the full build is successful on JDK 11?
   - [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)? 
   - [ ] If applicable, have you updated the `LICENSE` file, including the main 
`LICENSE` file under `nifi-assembly`?
   - [ ] If applicable, have you updated the `NOTICE` file, including the main 
`NOTICE` file found under `nifi-assembly`?
   - [x] If adding new Properties, have you added `.displayName` in addition to 
.name (programmatic access) for each of the new properties?
   
   ### For documentation related changes:
   - [x] Have you ensured that format looks appropriate for the output in which 
it is rendered?
   
   ### Note:
   Please ensure that once the PR is submitted, you check GitHub Actions CI for 
build issues and submit an update to your PR as soon as possible.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] fgerlits commented on a change in pull request #1031: MINIFICPP-1476 Improve parallel S3 request handling in S3 processors

2021-04-07 Thread GitBox


fgerlits commented on a change in pull request #1031:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1031#discussion_r608776773



##
File path: extensions/aws/processors/DeleteS3Object.h
##
@@ -65,6 +65,11 @@ class DeleteS3Object : public S3Processor {
   explicit DeleteS3Object(const std::string& name, const 
minifi::utils::Identifier& uuid, std::unique_ptr 
s3_request_sender)
 : S3Processor(name, uuid, 
logging::LoggerFactory::getLogger(), 
std::move(s3_request_sender)) {
   }
+
+  minifi::utils::optional 
buildDeleteS3RequestParams(
+const std::shared_ptr ,
+const std::shared_ptr _file,
+const CommonProperties _properties);

Review comment:
   minor, but this method could be `const` (also in the other operations)

##
File path: extensions/aws/processors/PutS3Object.cpp
##
@@ -206,7 +206,8 @@ 
minifi::utils::optional PutS3Object::buildP
 const std::shared_ptr ,
 const std::shared_ptr _file,
 const CommonProperties _properties) {
-  aws::s3::PutObjectRequestParameters params;
+  aws::s3::PutObjectRequestParameters params(common_properties.credentials, 
client_config_);
+  setClientConfig(params.client_config, common_properties);

Review comment:
   Just a suggestion, but if you made `setClientConfig()` a member of 
`RequestParameters` instead of a static function, then we could write 
`params.setClientConfig(common_properties)`, which would make it clearer (to 
me) that we are modifying the `params` object.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] mattyb149 commented on pull request #4901: NIFI-8326: Send records as individual messages in Kafka RecordSinks

2021-04-07 Thread GitBox


mattyb149 commented on pull request #4901:
URL: https://github.com/apache/nifi/pull/4901#issuecomment-815099839


   It's not ready yet, I need to change the producer.send() to not call get() 
directly after, or else each message will be ack'ed one at a time, which 
impacts performance.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Updated] (NIFI-8400) SystemDiagnostics throws NPE on Windows

2021-04-07 Thread Matt Burgess (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8400?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Matt Burgess updated NIFI-8400:
---
Fix Version/s: 1.14.0
   Status: Patch Available  (was: In Progress)

> SystemDiagnostics throws NPE on Windows
> ---
>
> Key: NIFI-8400
> URL: https://issues.apache.org/jira/browse/NIFI-8400
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Reporter: Matt Burgess
>Assignee: Matt Burgess
>Priority: Major
> Fix For: 1.14.0
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> SystemDiagnostics includes some Long member variables such as openFileHandles 
> that are not populated on Windows, so they remain null and when 
> getOpenFileHandles() is called, the null is cast to a long which throws an 
> NPE.
> The member variables should be long not Long, thereby getting a default value 
> of zero and avoiding an NPE when the values are not populated. If Long is 
> used elsewhere, a null check should be added to avoid possible NPEs when 
> calling the setter methods.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] mattyb149 opened a new pull request #4980: NIFI-8400: Use longs in SystemDiagnostics, add null checks

2021-04-07 Thread GitBox


mattyb149 opened a new pull request #4980:
URL: https://github.com/apache/nifi/pull/4980


   Thank you for submitting a contribution to Apache NiFi.
   
   Please provide a short description of the PR here:
   
    Description of PR
   
   Changes Long variables to long in SystemDiagnostics, add null checks before 
calling setters with Long arguments
   
   In order to streamline the review of the contribution we ask you
   to ensure the following steps have been taken:
   
   ### For all changes:
   - [x] Is there a JIRA ticket associated with this PR? Is it referenced 
in the commit message?
   
   - [x] Does your PR title start with **NIFI-** where  is the JIRA 
number you are trying to resolve? Pay particular attention to the hyphen "-" 
character.
   
   - [x] Has your PR been rebased against the latest commit within the target 
branch (typically `main`)?
   
   - [x] Is your initial contribution a single, squashed commit? _Additional 
commits in response to PR reviewer feedback should be made on this branch and 
pushed to allow change tracking. Do not `squash` or use `--force` when pushing 
to allow for clean monitoring of changes._
   
   ### For code changes:
   - [ ] Have you ensured that the full suite of tests is executed via `mvn 
-Pcontrib-check clean install` at the root `nifi` folder?
   - [ ] Have you written or updated unit tests to verify your changes?
   - [x] Have you verified that the full build is successful on JDK 8?
   - [ ] Have you verified that the full build is successful on JDK 11?
   - [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)? 
   - [ ] If applicable, have you updated the `LICENSE` file, including the main 
`LICENSE` file under `nifi-assembly`?
   - [ ] If applicable, have you updated the `NOTICE` file, including the main 
`NOTICE` file found under `nifi-assembly`?
   - [ ] If adding new Properties, have you added `.displayName` in addition to 
.name (programmatic access) for each of the new properties?
   
   ### For documentation related changes:
   - [ ] Have you ensured that format looks appropriate for the output in which 
it is rendered?
   
   ### Note:
   Please ensure that once the PR is submitted, you check GitHub Actions CI for 
build issues and submit an update to your PR as soon as possible.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Assigned] (NIFI-8400) SystemDiagnostics throws NPE on Windows

2021-04-07 Thread Matt Burgess (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8400?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Matt Burgess reassigned NIFI-8400:
--

Assignee: Matt Burgess

> SystemDiagnostics throws NPE on Windows
> ---
>
> Key: NIFI-8400
> URL: https://issues.apache.org/jira/browse/NIFI-8400
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Reporter: Matt Burgess
>Assignee: Matt Burgess
>Priority: Major
>
> SystemDiagnostics includes some Long member variables such as openFileHandles 
> that are not populated on Windows, so they remain null and when 
> getOpenFileHandles() is called, the null is cast to a long which throws an 
> NPE.
> The member variables should be long not Long, thereby getting a default value 
> of zero and avoiding an NPE when the values are not populated. If Long is 
> used elsewhere, a null check should be added to avoid possible NPEs when 
> calling the setter methods.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (NIFI-8400) SystemDiagnostics throws NPE on Windows

2021-04-07 Thread Otto Fowler (Jira)


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

Otto Fowler commented on NIFI-8400:
---

If you read this description, and initially thought "That variable name doesn't 
seem very long", please leave a comment here.
:D

> SystemDiagnostics throws NPE on Windows
> ---
>
> Key: NIFI-8400
> URL: https://issues.apache.org/jira/browse/NIFI-8400
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Reporter: Matt Burgess
>Priority: Major
>
> SystemDiagnostics includes some Long member variables such as openFileHandles 
> that are not populated on Windows, so they remain null and when 
> getOpenFileHandles() is called, the null is cast to a long which throws an 
> NPE.
> The member variables should be long not Long, thereby getting a default value 
> of zero and avoiding an NPE when the values are not populated. If Long is 
> used elsewhere, a null check should be added to avoid possible NPEs when 
> calling the setter methods.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (NIFI-8400) SystemDiagnostics throws NPE on Windows

2021-04-07 Thread Matt Burgess (Jira)
Matt Burgess created NIFI-8400:
--

 Summary: SystemDiagnostics throws NPE on Windows
 Key: NIFI-8400
 URL: https://issues.apache.org/jira/browse/NIFI-8400
 Project: Apache NiFi
  Issue Type: Bug
  Components: Core Framework
Reporter: Matt Burgess


SystemDiagnostics includes some Long member variables such as openFileHandles 
that are not populated on Windows, so they remain null and when 
getOpenFileHandles() is called, the null is cast to a long which throws an NPE.

The member variables should be long not Long, thereby getting a default value 
of zero and avoiding an NPE when the values are not populated. If Long is used 
elsewhere, a null check should be added to avoid possible NPEs when calling the 
setter methods.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] pvillard31 commented on pull request #4939: NIFI-8341 Support Multi Hosts in AMQP Processors

2021-04-07 Thread GitBox


pvillard31 commented on pull request #4939:
URL: https://github.com/apache/nifi/pull/4939#issuecomment-815002530


   Yeah fair enough. Not in a position to merge right now but will do later 
today if no one else does before me.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] lordgamez commented on a change in pull request #1043: MINIFICPP-1359 Implement FollowRedirects property in InvokeHTTP

2021-04-07 Thread GitBox


lordgamez commented on a change in pull request #1043:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1043#discussion_r608752782



##
File path: extensions/http-curl/tests/VerifyInvokeHTTPTest.cpp
##
@@ -120,6 +126,31 @@ class VerifyInvokeHTTPOKResponse : public VerifyInvokeHTTP 
{
   }
 };
 
+class VerifyInvokeHTTPOK200Response : public VerifyInvokeHTTP {
+ public:
+  void runAssertions() override {
+using org::apache::nifi::minifi::utils::verifyLogLinePresenceInPollTime;
+assert(verifyLogLinePresenceInPollTime(std::chrono::seconds(6),
+"key:invokehttp.status.code value:200",
+"response code 200"));

Review comment:
   It seems so. At first I wanted to make a separate handler for it, but 
after seeing it automatically returns `HTTP 200 OK` after redirecting to `/` 
and no other handler returns code `200` I decided to use that.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] timeabarna commented on pull request #4973: NIFI-8373 Add Kerberos support to Accumulo processors

2021-04-07 Thread GitBox


timeabarna commented on pull request #4973:
URL: https://github.com/apache/nifi/pull/4973#issuecomment-814974273


   @joshelser @bbende Josh and Bryan thank you very much for your help, PR has 
been updated


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] nabmoh123 commented on pull request #4939: NIFI-8341 Support Multi Hosts in AMQP Processors

2021-04-07 Thread GitBox


nabmoh123 commented on pull request #4939:
URL: https://github.com/apache/nifi/pull/4939#issuecomment-814967533


   > I still think that a custom validate method makes sense. Especially to 
make the processor invalid if brokers, host, and port are all set. Because in 
that case it could confuse the users wrt to which properties are actually used. 
I acknowledge this is explained in the properties description but this would 
make things more "obvious".
   > 
   > We do that for some processors where it's possible to configure the same 
"thing" via multiple properties after we added some new properties over time 
and we kept the old ones to not break backward compatibility.
   > 
   > That's my only remaining comment, latest changes look good to me.
   
   I could implement this, but it would require me to take off the default 
values for Host Name and Port. Otherwise, whenever Brokers is set, Host Name 
will take on its default value and cause a warning to appear. I'm not sure 
which is the lesser of two evils here, removing old functionality or not adding 
in clear and concise validation to ensure users understand which property is 
used.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Assigned] (NIFI-8148) Selecting field from array with QueryRecord routes to failure

2021-04-07 Thread Jon Kessler (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8148?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jon Kessler reassigned NIFI-8148:
-

Assignee: (was: Jon Kessler)

> Selecting field from array with QueryRecord routes to failure
> -
>
> Key: NIFI-8148
> URL: https://issues.apache.org/jira/browse/NIFI-8148
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Extensions
>Reporter: Mark Payne
>Priority: Major
>
> Given the following JSON document coming into QueryRecord:
> {{ {}}
> {{"name": "John Doe",}}
> {{"try": [}}
> {{{}}
> {{"workAddress": {}}
> {{"number": "123",}}
> {{"street": "5th Avenue",}}
> {{"city": "New York",}}
> {{"state": "NY",}}
> {{"zip": "10020"}}
> {{},}}
> {{"homeAddress": {}}
> {{"number": "456",}}
> {{"street": "116th Avenue",}}
> {{"city": "New York",}}
> {{"state": "NY",}}
> {{"zip": "11697"}}
> {{}}}
> {{}}}
> {{]}}
> {{}}}
> When using a JSON Reader (inferred schema) and JSON Writer (inherit record 
> schema), we should be able to use the query:
> SELECT RPATH(try, '/*/zip') AS zip
> FROM FLOWFILE
> The result should be two records, each consisting of a single field named 
> 'zip' that is of type String.
> Currently, it throws an Exception and routes to failure.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] JonathanKessler commented on pull request #4780: NIFI-8126 Include Total Queued Duration in ConnectionStatus metrics

2021-04-07 Thread GitBox


JonathanKessler commented on pull request #4780:
URL: https://github.com/apache/nifi/pull/4780#issuecomment-814925343


   @markap14, just wanted to ping you to please take a second look when you 
have a moment.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] adam-markovics commented on a change in pull request #1042: MINIFICPP-1457 - Implement InputRequirements

2021-04-07 Thread GitBox


adam-markovics commented on a change in pull request #1042:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1042#discussion_r608642381



##
File path: extensions/standard-processors/processors/TailFile.h
##
@@ -71,7 +71,7 @@ enum class Mode {
   SINGLE, MULTIPLE, UNDEFINED
 };
 
-class TailFile : public core::Processor {
+class TailFile : public core::Processor, public 
core::InputRequirementAnnotation {

Review comment:
   As we could have more types of annotations (other than input), I 
slightly modified it to:
   core::annotation::input::Forbidden

##
File path: libminifi/include/core/Annotation.h
##
@@ -0,0 +1,77 @@
+/**
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#pragma once
+
+#include 
+
+namespace org {
+namespace apache {
+namespace nifi {
+namespace minifi {
+namespace core {
+
+template 
+struct AnnotationBase {

Review comment:
   Okay, I understand now, it's done.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Resolved] (NIFI-7912) Site-to-Site over HTTP fails for FlowFiles over 100MB

2021-04-07 Thread David Handermann (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-7912?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

David Handermann resolved NIFI-7912.

Fix Version/s: 1.14.0
   Resolution: Fixed

> Site-to-Site over HTTP fails for FlowFiles over 100MB
> -
>
> Key: NIFI-7912
> URL: https://issues.apache.org/jira/browse/NIFI-7912
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Affects Versions: 1.12.1
>Reporter: Pierre Villard
>Assignee: Nathan Gough
>Priority: Major
> Fix For: 1.14.0
>
>  Time Spent: 2h 40m
>  Remaining Estimate: 0h
>
> When using Site-to-Site over HTTP and trying to send FlowFiles larger than 
> 100MB, it fails with the following errors.
> {noformat}
> 2020-10-12 16:25:23,132 ERROR [NiFi Web Server-31] 
> o.g.j.server.ServerRuntime$Responder An I/O error has occurred while writing 
> a response message entity to the container output stream.
> org.glassfish.jersey.server.internal.process.MappableException: 
> org.apache.nifi.processor.exception.ProcessException: 
> java.lang.InterruptedException
> at 
> org.glassfish.jersey.server.internal.MappableExceptionWrapperInterceptor.aroundWriteTo(MappableExceptionWrapperInterceptor.java:91)
> at 
> org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:163)
> at 
> org.glassfish.jersey.message.internal.MessageBodyFactory.writeTo(MessageBodyFactory.java:1135)
> at 
> org.glassfish.jersey.server.ServerRuntime$Responder.writeResponse(ServerRuntime.java:662)
> at 
> org.glassfish.jersey.server.ServerRuntime$Responder.processResponse(ServerRuntime.java:395)
> at 
> org.glassfish.jersey.server.ServerRuntime$Responder.process(ServerRuntime.java:385)
> at 
> org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:280)
> at org.glassfish.jersey.internal.Errors$1.call(Errors.java:272)
> at org.glassfish.jersey.internal.Errors$1.call(Errors.java:268)
> at org.glassfish.jersey.internal.Errors.process(Errors.java:316)
> at org.glassfish.jersey.internal.Errors.process(Errors.java:298)
> at org.glassfish.jersey.internal.Errors.process(Errors.java:268)
> at 
> org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:289)
> at 
> org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:256)
> at 
> org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:703)
> at 
> org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:416)
> at 
> org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:370)
> at 
> org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:389)
> at 
> org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:342)
> at 
> org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:229)
> at 
> org.eclipse.jetty.servlet.ServletHolder$NotAsyncServlet.service(ServletHolder.java:1395)
> at 
> org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:755)
> at 
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
> at 
> org.apache.nifi.web.filter.RequestLogger.doFilter(RequestLogger.java:66)
> at 
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
> at 
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:317)
> at 
> org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:127)
> at 
> org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
> at 
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
> at 
> org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137)
> at 
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
> at 
> org.apache.nifi.web.security.NiFiAuthenticationFilter.authenticate(NiFiAuthenticationFilter.java:100)
> at 
> org.apache.nifi.web.security.NiFiAuthenticationFilter.doFilter(NiFiAuthenticationFilter.java:59)
> at 
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
> at 
> org.apache.nifi.web.security.NiFiAuthenticationFilter.authenticate(NiFiAuthenticationFilter.java:100)
> at 
> 

[jira] [Commented] (NIFI-7912) Site-to-Site over HTTP fails for FlowFiles over 100MB

2021-04-07 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on NIFI-7912:
---

Commit 9da3b1ec01555a5f36047f500b784edffd2f80b3 in nifi's branch 
refs/heads/main from Nathan Gough
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=9da3b1e ]

NIFI-7912 - Added properties to configure DoSFilter timeout and whitelisted 
addresses

- Added nifi.web.request.ip.whitelist property to set DoSFilter.ipWhitelist
- Added nifi.web.request.timeout property to set DoSFilter.maxRequestMs with 
default of 60 seconds

This closes #4972

Signed-off-by: David Handermann 


> Site-to-Site over HTTP fails for FlowFiles over 100MB
> -
>
> Key: NIFI-7912
> URL: https://issues.apache.org/jira/browse/NIFI-7912
> Project: Apache NiFi
>  Issue Type: Bug
>  Components: Core Framework
>Affects Versions: 1.12.1
>Reporter: Pierre Villard
>Assignee: Nathan Gough
>Priority: Major
>  Time Spent: 2.5h
>  Remaining Estimate: 0h
>
> When using Site-to-Site over HTTP and trying to send FlowFiles larger than 
> 100MB, it fails with the following errors.
> {noformat}
> 2020-10-12 16:25:23,132 ERROR [NiFi Web Server-31] 
> o.g.j.server.ServerRuntime$Responder An I/O error has occurred while writing 
> a response message entity to the container output stream.
> org.glassfish.jersey.server.internal.process.MappableException: 
> org.apache.nifi.processor.exception.ProcessException: 
> java.lang.InterruptedException
> at 
> org.glassfish.jersey.server.internal.MappableExceptionWrapperInterceptor.aroundWriteTo(MappableExceptionWrapperInterceptor.java:91)
> at 
> org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:163)
> at 
> org.glassfish.jersey.message.internal.MessageBodyFactory.writeTo(MessageBodyFactory.java:1135)
> at 
> org.glassfish.jersey.server.ServerRuntime$Responder.writeResponse(ServerRuntime.java:662)
> at 
> org.glassfish.jersey.server.ServerRuntime$Responder.processResponse(ServerRuntime.java:395)
> at 
> org.glassfish.jersey.server.ServerRuntime$Responder.process(ServerRuntime.java:385)
> at 
> org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:280)
> at org.glassfish.jersey.internal.Errors$1.call(Errors.java:272)
> at org.glassfish.jersey.internal.Errors$1.call(Errors.java:268)
> at org.glassfish.jersey.internal.Errors.process(Errors.java:316)
> at org.glassfish.jersey.internal.Errors.process(Errors.java:298)
> at org.glassfish.jersey.internal.Errors.process(Errors.java:268)
> at 
> org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:289)
> at 
> org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:256)
> at 
> org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:703)
> at 
> org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:416)
> at 
> org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:370)
> at 
> org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:389)
> at 
> org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:342)
> at 
> org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:229)
> at 
> org.eclipse.jetty.servlet.ServletHolder$NotAsyncServlet.service(ServletHolder.java:1395)
> at 
> org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:755)
> at 
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
> at 
> org.apache.nifi.web.filter.RequestLogger.doFilter(RequestLogger.java:66)
> at 
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
> at 
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:317)
> at 
> org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:127)
> at 
> org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
> at 
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
> at 
> org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137)
> at 
> org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
> at 
> 

[GitHub] [nifi] asfgit closed pull request #4972: NIFI-7912 - Added a Denial of Service filter wrapper called NiFiDoSFi…

2021-04-07 Thread GitBox


asfgit closed pull request #4972:
URL: https://github.com/apache/nifi/pull/4972


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] exceptionfactory commented on pull request #4972: NIFI-7912 - Added a Denial of Service filter wrapper called NiFiDoSFi…

2021-04-07 Thread GitBox


exceptionfactory commented on pull request #4972:
URL: https://github.com/apache/nifi/pull/4972#issuecomment-814876578


   > @thenatog Thanks for the review changes!
   > @exceptionfactory I have no more comments, +1 from my side too.
   
   Thanks for the confirmation @turcsanyip! Merging.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] markap14 commented on pull request #4950: NIFI-8380: Allow for an extensions.directory property to specify wher…

2021-04-07 Thread GitBox


markap14 commented on pull request #4950:
URL: https://github.com/apache/nifi/pull/4950#issuecomment-814871049


   Awesome! Thanks @akatona84  and @urbandan for such thorough testing & 
review! And thanks @pvillard31 for reviewing & merging!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] gresockj commented on a change in pull request #4976: NIFI-3862: Added Issuer DN support to ListenHTTP

2021-04-07 Thread GitBox


gresockj commented on a change in pull request #4976:
URL: https://github.com/apache/nifi/pull/4976#discussion_r608586852



##
File path: 
nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/test/java/org/apache/nifi/processors/standard/TestListenHTTP.java
##
@@ -298,6 +299,56 @@ public void 
testSecureTwoWaySslPOSTRequestsReceivedWithoutEL() throws Exception
 testPOSTRequestsReceived(HttpServletResponse.SC_OK, true, true);
 }
 
+@Test
+public void 
testSecureTwoWaySslPOSTRequestsReceivedWithAuthorizedSubjectDn() throws 
Exception {

Review comment:
   Good point, will remove this one.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] gresockj commented on a change in pull request #4976: NIFI-3862: Added Issuer DN support to ListenHTTP

2021-04-07 Thread GitBox


gresockj commented on a change in pull request #4976:
URL: https://github.com/apache/nifi/pull/4976#discussion_r608586502



##
File path: 
nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/test/java/org/apache/nifi/processors/standard/TestListenHTTP.java
##
@@ -298,6 +299,56 @@ public void 
testSecureTwoWaySslPOSTRequestsReceivedWithoutEL() throws Exception
 testPOSTRequestsReceived(HttpServletResponse.SC_OK, true, true);
 }
 
+@Test
+public void 
testSecureTwoWaySslPOSTRequestsReceivedWithAuthorizedSubjectDn() throws 
Exception {
+
configureProcessorSslContextService(ListenHTTP.ClientAuthentication.REQUIRED, 
serverConfiguration);
+
+runner.setProperty(ListenHTTP.PORT, Integer.toString(availablePort));
+runner.setProperty(ListenHTTP.AUTHORIZED_DN_PATTERN, LOCALHOST_DN);
+runner.setProperty(ListenHTTP.BASE_PATH, HTTP_BASE_PATH);
+runner.assertValid();
+
+testPOSTRequestsReceived(HttpServletResponse.SC_OK, true, true);
+}
+
+@Test
+public void 
testSecureTwoWaySslPOSTRequestsReceivedWithUnauthorizedSubjectDn() throws 
Exception {
+
configureProcessorSslContextService(ListenHTTP.ClientAuthentication.REQUIRED, 
serverConfiguration);
+
+runner.setProperty(ListenHTTP.PORT, Integer.toString(availablePort));
+runner.setProperty(ListenHTTP.AUTHORIZED_DN_PATTERN, "CN=other");
+runner.setProperty(ListenHTTP.BASE_PATH, HTTP_BASE_PATH);
+runner.assertValid();
+
+testPOSTRequestsReceived(HttpServletResponse.SC_FORBIDDEN, true, true);
+}
+
+@Test
+public void 
testSecureTwoWaySslPOSTRequestsReceivedWithAuthorizedIssuerDn() throws 
Exception {

Review comment:
   I wanted to show that configuring the subject and issuer DN patterns to 
something other than .* would actually work if the patterns matched, so I'd 
like to keep this one.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] gresockj commented on a change in pull request #4976: NIFI-3862: Added Issuer DN support to ListenHTTP

2021-04-07 Thread GitBox


gresockj commented on a change in pull request #4976:
URL: https://github.com/apache/nifi/pull/4976#discussion_r608584778



##
File path: 
nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/servlets/ListenHTTPServlet.java
##
@@ -335,8 +348,9 @@ public void process(final OutputStream rawOut) throws 
IOException {
 }
 
 flowFile = session.putAllAttributes(flowFile, attributes);
-flowFile = saveRequestDetailsAsAttributes(request, session, 
foundSubject, flowFile);
-session.getProvenanceReporter().receive(flowFile, 
request.getRequestURL().toString(), sourceSystemFlowFileIdentifier, "Remote 
DN=" + foundSubject, transferMillis);
+flowFile = saveRequestDetailsAsAttributes(request, session, 
foundSubject, foundIssuer, flowFile);
+final String details = String.format("Remote DN=%s, Issuer DN=%s", 
foundSubject, foundIssuer);
+session.getProvenanceReporter().receive(flowFile, 
request.getRequestURL().toString(), sourceSystemFlowFileIdentifier, details + 
foundIssuer, transferMillis);

Review comment:
   Yep, certainly a typo.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Resolved] (NIFI-8380) Stateless NiFi Kafka connector should allow separate directories for extensions and base nars

2021-04-07 Thread Pierre Villard (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8380?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pierre Villard resolved NIFI-8380.
--
Fix Version/s: 1.14.0
   Resolution: Fixed

> Stateless NiFi Kafka connector should allow separate directories for 
> extensions and base nars
> -
>
> Key: NIFI-8380
> URL: https://issues.apache.org/jira/browse/NIFI-8380
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Mark Payne
>Assignee: Mark Payne
>Priority: Major
> Fix For: 1.14.0
>
>  Time Spent: 1h 50m
>  Remaining Estimate: 0h
>
> We should allow separating out the nar directory and the extensions directory 
> so that they are not forced to be co-located. This will make upgrades simpler 
> and addresses issues where the user running the connector may not have write 
> permissions on the directory where the connector is deployed



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (NIFI-8380) Stateless NiFi Kafka connector should allow separate directories for extensions and base nars

2021-04-07 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on NIFI-8380:
---

Commit b79987918a3f8e3cb69e3d21176f09704c441707 in nifi's branch 
refs/heads/main from Mark Payne
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=b799879 ]

NIFI-8380: Allow for an extensions.directory property to specify where to place 
downloaded files. Also fixed an issue that was encountered, when a Source 
Processor is scheduled for Primary Node Only but more than 1 task is set. In 
that case, even though only a single task will should be scheduled, an 
Exception was getting thrown because @OnScheduled methods of Processors were 
still called. To avoid this, moved the initialization of the dataflow outside 
of the creation of the dataflow so that initialization can be triggered only 
when appropriate.

NIFI-8380: Removed requirement in validation for working directory and 
extensions directory to exist; removed auto-creation of directories in 
validation

NIFI-8380: Fixed a few thrading bugs, so that if we have multiple threads 
trying to download/unpack extensions, we properly synchronize the unpacking and 
unpack into the correct sub-directory under the working directory

Signed-off-by: Pierre Villard 

This closes #4950.


> Stateless NiFi Kafka connector should allow separate directories for 
> extensions and base nars
> -
>
> Key: NIFI-8380
> URL: https://issues.apache.org/jira/browse/NIFI-8380
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Mark Payne
>Assignee: Mark Payne
>Priority: Major
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> We should allow separating out the nar directory and the extensions directory 
> so that they are not forced to be co-located. This will make upgrades simpler 
> and addresses issues where the user running the connector may not have write 
> permissions on the directory where the connector is deployed



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (NIFI-8380) Stateless NiFi Kafka connector should allow separate directories for extensions and base nars

2021-04-07 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on NIFI-8380:
---

Commit b79987918a3f8e3cb69e3d21176f09704c441707 in nifi's branch 
refs/heads/main from Mark Payne
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=b799879 ]

NIFI-8380: Allow for an extensions.directory property to specify where to place 
downloaded files. Also fixed an issue that was encountered, when a Source 
Processor is scheduled for Primary Node Only but more than 1 task is set. In 
that case, even though only a single task will should be scheduled, an 
Exception was getting thrown because @OnScheduled methods of Processors were 
still called. To avoid this, moved the initialization of the dataflow outside 
of the creation of the dataflow so that initialization can be triggered only 
when appropriate.

NIFI-8380: Removed requirement in validation for working directory and 
extensions directory to exist; removed auto-creation of directories in 
validation

NIFI-8380: Fixed a few thrading bugs, so that if we have multiple threads 
trying to download/unpack extensions, we properly synchronize the unpacking and 
unpack into the correct sub-directory under the working directory

Signed-off-by: Pierre Villard 

This closes #4950.


> Stateless NiFi Kafka connector should allow separate directories for 
> extensions and base nars
> -
>
> Key: NIFI-8380
> URL: https://issues.apache.org/jira/browse/NIFI-8380
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Mark Payne
>Assignee: Mark Payne
>Priority: Major
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> We should allow separating out the nar directory and the extensions directory 
> so that they are not forced to be co-located. This will make upgrades simpler 
> and addresses issues where the user running the connector may not have write 
> permissions on the directory where the connector is deployed



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (NIFI-8380) Stateless NiFi Kafka connector should allow separate directories for extensions and base nars

2021-04-07 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on NIFI-8380:
---

Commit b79987918a3f8e3cb69e3d21176f09704c441707 in nifi's branch 
refs/heads/main from Mark Payne
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=b799879 ]

NIFI-8380: Allow for an extensions.directory property to specify where to place 
downloaded files. Also fixed an issue that was encountered, when a Source 
Processor is scheduled for Primary Node Only but more than 1 task is set. In 
that case, even though only a single task will should be scheduled, an 
Exception was getting thrown because @OnScheduled methods of Processors were 
still called. To avoid this, moved the initialization of the dataflow outside 
of the creation of the dataflow so that initialization can be triggered only 
when appropriate.

NIFI-8380: Removed requirement in validation for working directory and 
extensions directory to exist; removed auto-creation of directories in 
validation

NIFI-8380: Fixed a few thrading bugs, so that if we have multiple threads 
trying to download/unpack extensions, we properly synchronize the unpacking and 
unpack into the correct sub-directory under the working directory

Signed-off-by: Pierre Villard 

This closes #4950.


> Stateless NiFi Kafka connector should allow separate directories for 
> extensions and base nars
> -
>
> Key: NIFI-8380
> URL: https://issues.apache.org/jira/browse/NIFI-8380
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Mark Payne
>Assignee: Mark Payne
>Priority: Major
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> We should allow separating out the nar directory and the extensions directory 
> so that they are not forced to be co-located. This will make upgrades simpler 
> and addresses issues where the user running the connector may not have write 
> permissions on the directory where the connector is deployed



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] pvillard31 commented on pull request #4950: NIFI-8380: Allow for an extensions.directory property to specify wher…

2021-04-07 Thread GitBox


pvillard31 commented on pull request #4950:
URL: https://github.com/apache/nifi/pull/4950#issuecomment-814836289


   Merged to main, thanks @markap14 @akatona84 @urbandan 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] asfgit closed pull request #4950: NIFI-8380: Allow for an extensions.directory property to specify wher…

2021-04-07 Thread GitBox


asfgit closed pull request #4950:
URL: https://github.com/apache/nifi/pull/4950


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] turcsanyip commented on pull request #4972: NIFI-7912 - Added a Denial of Service filter wrapper called NiFiDoSFi…

2021-04-07 Thread GitBox


turcsanyip commented on pull request #4972:
URL: https://github.com/apache/nifi/pull/4972#issuecomment-814786327


   @thenatog Thanks for the review changes!
   @exceptionfactory I have no more comments, +1 from my side too.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] fgerlits opened a new pull request #1046: MINIFICPP-1032 Refactor parse_url

2021-04-07 Thread GitBox


fgerlits opened a new pull request #1046:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1046


   https://issues.apache.org/jira/browse/MINIFICPP-1032
   
   Modernize the parse_url() function and add error checking.
   
   ---
   
   Thank you for submitting a contribution to Apache NiFi - MiNiFi C++.
   
   In order to streamline the review of the contribution we ask you
   to ensure the following steps have been taken:
   
   ### For all changes:
   - [x] Is there a JIRA ticket associated with this PR? Is it referenced
in the commit message?
   
   - [x] Does your PR title start with MINIFICPP- where  is the JIRA 
number you are trying to resolve? Pay particular attention to the hyphen "-" 
character.
   
   - [x] Has your PR been rebased against the latest commit within the target 
branch (typically main)?
   
   - [x] Is your initial contribution a single, squashed commit?
   
   ### For code changes:
   - [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?
   - [ ] If applicable, have you updated the LICENSE file?
   - [ ] If applicable, have you updated the NOTICE file?
   
   ### For documentation related changes:
   - [ ] Have you ensured that format looks appropriate for the output in which 
it is rendered?
   
   ### Note:
   Please ensure that once the PR is submitted, you check GitHub Actions CI 
results for build issues and submit an update to your PR as soon as possible.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] adamdebreceni commented on a change in pull request #1042: MINIFICPP-1457 - Implement InputRequirements

2021-04-07 Thread GitBox


adamdebreceni commented on a change in pull request #1042:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1042#discussion_r608475655



##
File path: libminifi/include/core/Annotation.h
##
@@ -0,0 +1,77 @@
+/**
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#pragma once
+
+#include 
+
+namespace org {
+namespace apache {
+namespace nifi {
+namespace minifi {
+namespace core {
+
+template 
+struct AnnotationBase {

Review comment:
   is `dynamic_cast*>(_)` malformed?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] adamdebreceni commented on a change in pull request #1043: MINIFICPP-1359 Implement FollowRedirects property in InvokeHTTP

2021-04-07 Thread GitBox


adamdebreceni commented on a change in pull request #1043:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1043#discussion_r608472239



##
File path: extensions/http-curl/tests/VerifyInvokeHTTPTest.cpp
##
@@ -120,6 +126,31 @@ class VerifyInvokeHTTPOKResponse : public VerifyInvokeHTTP 
{
   }
 };
 
+class VerifyInvokeHTTPOK200Response : public VerifyInvokeHTTP {
+ public:
+  void runAssertions() override {
+using org::apache::nifi::minifi::utils::verifyLogLinePresenceInPollTime;
+assert(verifyLogLinePresenceInPollTime(std::chrono::seconds(6),
+"key:invokehttp.status.code value:200",
+"response code 200"));

Review comment:
   which handler responds with `200`? we redirect to `/`, does the civetweb 
have some default handler on `/`?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] adam-markovics commented on a change in pull request #1042: MINIFICPP-1457 - Implement InputRequirements

2021-04-07 Thread GitBox


adam-markovics commented on a change in pull request #1042:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1042#discussion_r608471765



##
File path: libminifi/include/core/Annotation.h
##
@@ -0,0 +1,77 @@
+/**
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#pragma once
+
+#include 
+
+namespace org {
+namespace apache {
+namespace nifi {
+namespace minifi {
+namespace core {
+
+template 
+struct AnnotationBase {

Review comment:
   It's possible that we will have more annotations in the future. We can 
get rid of AnnotationBase, but not InputRequirementAnnotationBase, as a 
non-template base class in necessary for the dynamic cast in 
Processor::getInputRequirement().




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] adamdebreceni commented on a change in pull request #1042: MINIFICPP-1457 - Implement InputRequirements

2021-04-07 Thread GitBox


adamdebreceni commented on a change in pull request #1042:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1042#discussion_r608449176



##
File path: extensions/standard-processors/processors/TailFile.h
##
@@ -71,7 +71,7 @@ enum class Mode {
   SINGLE, MULTIPLE, UNDEFINED
 };
 
-class TailFile : public core::Processor {
+class TailFile : public core::Processor, public 
core::InputRequirementAnnotation {

Review comment:
   we could introduce an `annotation` namespace in `core` and provide type 
aliases for these, like `core::annotation::InputForbidden`, this might make it 
more compact




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] adamdebreceni commented on a change in pull request #1042: MINIFICPP-1457 - Implement InputRequirements

2021-04-07 Thread GitBox


adamdebreceni commented on a change in pull request #1042:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1042#discussion_r608447451



##
File path: libminifi/include/core/Annotation.h
##
@@ -0,0 +1,77 @@
+/**
+
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#pragma once
+
+#include 
+
+namespace org {
+namespace apache {
+namespace nifi {
+namespace minifi {
+namespace core {
+
+template 
+struct AnnotationBase {

Review comment:
   are more kinds of annotations in the works? if so, we could drop the 
default definition, and specialize on `Annotation` thus we 
wouldn't need the `InputRequirementAnnotationBase` anymore




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Updated] (NIFI-8389) Grok Reader - raw data strategy when no match

2021-04-07 Thread Peter Turcsanyi (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8389?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Peter Turcsanyi updated NIFI-8389:
--
Fix Version/s: 1.14.0
   Resolution: Fixed
   Status: Resolved  (was: Patch Available)

> Grok Reader - raw data strategy when no match
> -
>
> Key: NIFI-8389
> URL: https://issues.apache.org/jira/browse/NIFI-8389
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Pierre Villard
>Assignee: Pierre Villard
>Priority: Major
> Fix For: 1.14.0
>
>  Time Spent: 1h 40m
>  Remaining Estimate: 0h
>
> At the moment, with the GrokReader, there are two options when a message does 
> not match the grok expression:
>  * append - this will append the message to the previous one
>  * skip - this will completely skip the message
> This improvement is to add a third option "raw" that will keep the message 
> and will generate a record with only null fields and the _raw field with the 
> raw message.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (NIFI-8389) Grok Reader - raw data strategy when no match

2021-04-07 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on NIFI-8389:
---

Commit f4ad658faee24b48a266e9efc53d2b275a473cdd in nifi's branch 
refs/heads/main from Pierre Villard
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=f4ad658 ]

NIFI-8389 - Grok Reader - raw data strategy when no match

added allowable value in property
added docs in additionalDetails

This closes #4966.

Signed-off-by: Peter Turcsanyi 


> Grok Reader - raw data strategy when no match
> -
>
> Key: NIFI-8389
> URL: https://issues.apache.org/jira/browse/NIFI-8389
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Pierre Villard
>Assignee: Pierre Villard
>Priority: Major
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> At the moment, with the GrokReader, there are two options when a message does 
> not match the grok expression:
>  * append - this will append the message to the previous one
>  * skip - this will completely skip the message
> This improvement is to add a third option "raw" that will keep the message 
> and will generate a record with only null fields and the _raw field with the 
> raw message.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] asfgit closed pull request #4966: NIFI-8389 - Grok Reader - raw data strategy when no match

2021-04-07 Thread GitBox


asfgit closed pull request #4966:
URL: https://github.com/apache/nifi/pull/4966


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] turcsanyip commented on pull request #4966: NIFI-8389 - Grok Reader - raw data strategy when no match

2021-04-07 Thread GitBox


turcsanyip commented on pull request #4966:
URL: https://github.com/apache/nifi/pull/4966#issuecomment-814669723


   @pvillard31 Thanks for the improvement!
   @ottobackwards Thanks for the review!
   
   Merging to main.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Updated] (NIFI-8390) Handle HBase namespaces in Atlas reporting task

2021-04-07 Thread Pierre Villard (Jira)


 [ 
https://issues.apache.org/jira/browse/NIFI-8390?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pierre Villard updated NIFI-8390:
-
Fix Version/s: 1.14.0
   Resolution: Fixed
   Status: Resolved  (was: Patch Available)

> Handle HBase namespaces in Atlas reporting task
> ---
>
> Key: NIFI-8390
> URL: https://issues.apache.org/jira/browse/NIFI-8390
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Peter Turcsanyi
>Assignee: Peter Turcsanyi
>Priority: Major
> Fix For: 1.14.0
>
> Attachments: hbase_namespace_default.png, 
> hbase_namespace_nifi_ns.png, hbase_table_default.png, hbase_table_nifi_ns.png
>
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> NiFi's Atlas reporting task creates hbase_table entities in Atlas from events 
> generated by different HBase processors. The hbase_table Atlas entity has a 
> reference to hbase_namespace which was optional earlier but it is mandatory 
> from Atlas 2.1 on.
> Implement handling hbase_namespace entities in NiFi. Creation of hbase_table 
> currently fails due to the missing namespace entity.
> Screenshots of sample entities generated with Atlas' HBase Hook attached (as 
> a reference for filling the properties in properly).



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] pvillard31 commented on pull request #4977: NIFI-8390: Handle HBase namespaces in Atlas reporting task

2021-04-07 Thread GitBox


pvillard31 commented on pull request #4977:
URL: https://github.com/apache/nifi/pull/4977#issuecomment-814656430


   Thanks @turcsanyip - merged to main


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (NIFI-8390) Handle HBase namespaces in Atlas reporting task

2021-04-07 Thread ASF subversion and git services (Jira)


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

ASF subversion and git services commented on NIFI-8390:
---

Commit 4b852ba7c89097da25bcf9160631eca6e9d9ac28 in nifi's branch 
refs/heads/main from Peter Turcsanyi
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=4b852ba ]

NIFI-8390: Handle HBase namespaces in Atlas reporting task

Signed-off-by: Pierre Villard 

This closes #4977.


> Handle HBase namespaces in Atlas reporting task
> ---
>
> Key: NIFI-8390
> URL: https://issues.apache.org/jira/browse/NIFI-8390
> Project: Apache NiFi
>  Issue Type: Improvement
>  Components: Extensions
>Reporter: Peter Turcsanyi
>Assignee: Peter Turcsanyi
>Priority: Major
> Attachments: hbase_namespace_default.png, 
> hbase_namespace_nifi_ns.png, hbase_table_default.png, hbase_table_nifi_ns.png
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> NiFi's Atlas reporting task creates hbase_table entities in Atlas from events 
> generated by different HBase processors. The hbase_table Atlas entity has a 
> reference to hbase_namespace which was optional earlier but it is mandatory 
> from Atlas 2.1 on.
> Implement handling hbase_namespace entities in NiFi. Creation of hbase_table 
> currently fails due to the missing namespace entity.
> Screenshots of sample entities generated with Atlas' HBase Hook attached (as 
> a reference for filling the properties in properly).



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi] asfgit closed pull request #4977: NIFI-8390: Handle HBase namespaces in Atlas reporting task

2021-04-07 Thread GitBox


asfgit closed pull request #4977:
URL: https://github.com/apache/nifi/pull/4977


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] pvillard31 commented on pull request #4901: NIFI-8326: Send records as individual messages in Kafka RecordSinks

2021-04-07 Thread GitBox


pvillard31 commented on pull request #4901:
URL: https://github.com/apache/nifi/pull/4901#issuecomment-814655520


   Hey @mattyb149 - is this ready for final review?
   (also, while playing more with this, I realized some authN methods are 
missing https://issues.apache.org/jira/browse/NIFI-8399)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Created] (NIFI-8399) Kerberos username/password for KafkaRecordSink

2021-04-07 Thread Pierre Villard (Jira)
Pierre Villard created NIFI-8399:


 Summary: Kerberos username/password for KafkaRecordSink
 Key: NIFI-8399
 URL: https://issues.apache.org/jira/browse/NIFI-8399
 Project: Apache NiFi
  Issue Type: Improvement
  Components: Extensions
Reporter: Pierre Villard


It appears that KafkaRecordSink does not support the same range of 
authentication methods as in the Kafka processors. In particular, supporting 
Kerberos username/password would be very useful.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [nifi-minifi-cpp] adamdebreceni opened a new pull request #1045: MINIFICPP-1535 - Support process groups

2021-04-07 Thread GitBox


adamdebreceni opened a new pull request #1045:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1045


   Thank you for submitting a contribution to Apache NiFi - MiNiFi C++.
   
   In order to streamline the review of the contribution we ask you
   to ensure the following steps have been taken:
   
   ### For all changes:
   - [ ] Is there a JIRA ticket associated with this PR? Is it referenced
in the commit message?
   
   - [ ] Does your PR title start with MINIFICPP- where  is the JIRA 
number you are trying to resolve? Pay particular attention to the hyphen "-" 
character.
   
   - [ ] Has your PR been rebased against the latest commit within the target 
branch (typically main)?
   
   - [ ] Is your initial contribution a single, squashed commit?
   
   ### For code changes:
   - [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?
   - [ ] If applicable, have you updated the LICENSE file?
   - [ ] If applicable, have you updated the NOTICE file?
   
   ### For documentation related changes:
   - [ ] Have you ensured that format looks appropriate for the output in which 
it is rendered?
   
   ### Note:
   Please ensure that once the PR is submitted, you check GitHub Actions CI 
results for build issues and submit an update to your PR as soon as possible.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] aminadinari19 commented on a change in pull request #1040: MINIFICPP-1329- Fix implementation and usages of string to bool

2021-04-07 Thread GitBox


aminadinari19 commented on a change in pull request #1040:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1040#discussion_r608373420



##
File path: extensions/standard-processors/processors/HashContent.cpp
##
@@ -84,6 +82,7 @@ void HashContent::onTrigger(core::ProcessContext *, 
core::ProcessSession *sessio
   }
 
   if (failOnEmpty_ && flowFile->getSize() == 0) {
+logger_->log_trace("Failure as flow file is empty");

Review comment:
   Yeah I added it to checks logs in testing. How do you suggest I tweak 
this?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi] timeabarna commented on a change in pull request #4973: NIFI-8373 Add Kerberos support to Accumulo processors

2021-04-07 Thread GitBox


timeabarna commented on a change in pull request #4973:
URL: https://github.com/apache/nifi/pull/4973#discussion_r608365626



##
File path: 
nifi-nar-bundles/nifi-accumulo-bundle/nifi-accumulo-services/src/main/java/org/apache/nifi/accumulo/controllerservices/AccumuloService.java
##
@@ -150,61 +176,92 @@ private AuthenticationToken getToken(final 
AuthenticationType type, final Config
 problems.add(new 
ValidationResult.Builder().valid(false).subject(ZOOKEEPER_QUORUM.getName()).explanation("Zookeepers
 must be supplied").build());
 }
 
-if (!validationContext.getProperty(ACCUMULO_USER).isSet()){
-problems.add(new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_USER.getName()).explanation("Accumulo
 user must be supplied").build());
-}
-
 final AuthenticationType type = validationContext.getProperty(
-AUTHENTICATION_TYPE).isSet() ? AuthenticationType.valueOf( 
validationContext.getProperty(AUTHENTICATION_TYPE).getValue() ) : 
AuthenticationType.PASSWORD;
+AUTHENTICATION_TYPE).isSet() ? AuthenticationType.valueOf( 
validationContext.getProperty(AUTHENTICATION_TYPE).getValue() ) : 
AuthenticationType.NONE;
 
 switch(type){
 case PASSWORD:
+if (!validationContext.getProperty(ACCUMULO_USER).isSet()){
+problems.add(
+new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_USER.getName()).explanation("Accumulo
 user must be supplied for the Password Authentication type").build());
+}
 if (!validationContext.getProperty(ACCUMULO_PASSWORD).isSet()){
 problems.add(
-new 
ValidationResult.Builder().valid(false).subject(AUTHENTICATION_TYPE.getName()).explanation("Password
 must be supplied for the Password Authentication type").build());
+new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_PASSWORD.getName())
+.explanation("Password must be supplied 
for the Password Authentication type").build());
+}
+break;
+case KERBEROS:
+if 
(!validationContext.getProperty(KERBEROS_CREDENTIALS_SERVICE).isSet()){
+problems.add(new 
ValidationResult.Builder().valid(false).subject(KERBEROS_CREDENTIALS_SERVICE.getName())
+.explanation("Kerberos credential service must be 
supplied for the Kerberos Authentication type").build());
 }
 break;
 default:
-problems.add(new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_PASSWORD.getName()).explanation("Non
 supported Authentication type").build());
+problems.add(new 
ValidationResult.Builder().valid(false).subject(AUTHENTICATION_TYPE.getName()).explanation("Non
 supported Authentication type").build());
 }
 
 return problems;
 }
 
 @OnEnabled
-public void onEnabled(final ConfigurationContext context) throws 
InitializationException, IOException, InterruptedException {
-if (!context.getProperty(INSTANCE_NAME).isSet() || 
!context.getProperty(ZOOKEEPER_QUORUM).isSet() || 
!context.getProperty(ACCUMULO_USER).isSet()){
+public void onEnabled(final ConfigurationContext context) throws 
InitializationException, IOException {
+if (!context.getProperty(INSTANCE_NAME).isSet() || 
!context.getProperty(ZOOKEEPER_QUORUM).isSet()) {
 throw new InitializationException("Instance name and Zookeeper 
Quorum must be specified");
 }
 
-
-
+final KerberosCredentialsService kerberosService = 
context.getProperty(KERBEROS_CREDENTIALS_SERVICE).asControllerService(KerberosCredentialsService.class);
 final String instanceName = 
context.getProperty(INSTANCE_NAME).evaluateAttributeExpressions().getValue();
 final String zookeepers = 
context.getProperty(ZOOKEEPER_QUORUM).evaluateAttributeExpressions().getValue();
-final String accumuloUser = 
context.getProperty(ACCUMULO_USER).evaluateAttributeExpressions().getValue();
+authType = AuthenticationType.valueOf( 
context.getProperty(AUTHENTICATION_TYPE).getValue());
+AuthenticationToken token;
 
-final AuthenticationType type = AuthenticationType.valueOf( 
context.getProperty(AUTHENTICATION_TYPE).getValue() );
+final Properties clientConf = new Properties();
+clientConf.setProperty("instance.zookeepers", zookeepers);
+clientConf.setProperty("instance.name", instanceName);
 
+switch(authType){
+case PASSWORD:
+final String accumuloUser = 
context.getProperty(ACCUMULO_USER).evaluateAttributeExpressions().getValue();
 
+token = new 
PasswordToken(context.getProperty(ACCUMULO_PASSWORD).getValue());
 
-final 

[GitHub] [nifi] timeabarna commented on a change in pull request #4973: NIFI-8373 Add Kerberos support to Accumulo processors

2021-04-07 Thread GitBox


timeabarna commented on a change in pull request #4973:
URL: https://github.com/apache/nifi/pull/4973#discussion_r608365626



##
File path: 
nifi-nar-bundles/nifi-accumulo-bundle/nifi-accumulo-services/src/main/java/org/apache/nifi/accumulo/controllerservices/AccumuloService.java
##
@@ -150,61 +176,92 @@ private AuthenticationToken getToken(final 
AuthenticationType type, final Config
 problems.add(new 
ValidationResult.Builder().valid(false).subject(ZOOKEEPER_QUORUM.getName()).explanation("Zookeepers
 must be supplied").build());
 }
 
-if (!validationContext.getProperty(ACCUMULO_USER).isSet()){
-problems.add(new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_USER.getName()).explanation("Accumulo
 user must be supplied").build());
-}
-
 final AuthenticationType type = validationContext.getProperty(
-AUTHENTICATION_TYPE).isSet() ? AuthenticationType.valueOf( 
validationContext.getProperty(AUTHENTICATION_TYPE).getValue() ) : 
AuthenticationType.PASSWORD;
+AUTHENTICATION_TYPE).isSet() ? AuthenticationType.valueOf( 
validationContext.getProperty(AUTHENTICATION_TYPE).getValue() ) : 
AuthenticationType.NONE;
 
 switch(type){
 case PASSWORD:
+if (!validationContext.getProperty(ACCUMULO_USER).isSet()){
+problems.add(
+new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_USER.getName()).explanation("Accumulo
 user must be supplied for the Password Authentication type").build());
+}
 if (!validationContext.getProperty(ACCUMULO_PASSWORD).isSet()){
 problems.add(
-new 
ValidationResult.Builder().valid(false).subject(AUTHENTICATION_TYPE.getName()).explanation("Password
 must be supplied for the Password Authentication type").build());
+new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_PASSWORD.getName())
+.explanation("Password must be supplied 
for the Password Authentication type").build());
+}
+break;
+case KERBEROS:
+if 
(!validationContext.getProperty(KERBEROS_CREDENTIALS_SERVICE).isSet()){
+problems.add(new 
ValidationResult.Builder().valid(false).subject(KERBEROS_CREDENTIALS_SERVICE.getName())
+.explanation("Kerberos credential service must be 
supplied for the Kerberos Authentication type").build());
 }
 break;
 default:
-problems.add(new 
ValidationResult.Builder().valid(false).subject(ACCUMULO_PASSWORD.getName()).explanation("Non
 supported Authentication type").build());
+problems.add(new 
ValidationResult.Builder().valid(false).subject(AUTHENTICATION_TYPE.getName()).explanation("Non
 supported Authentication type").build());
 }
 
 return problems;
 }
 
 @OnEnabled
-public void onEnabled(final ConfigurationContext context) throws 
InitializationException, IOException, InterruptedException {
-if (!context.getProperty(INSTANCE_NAME).isSet() || 
!context.getProperty(ZOOKEEPER_QUORUM).isSet() || 
!context.getProperty(ACCUMULO_USER).isSet()){
+public void onEnabled(final ConfigurationContext context) throws 
InitializationException, IOException {
+if (!context.getProperty(INSTANCE_NAME).isSet() || 
!context.getProperty(ZOOKEEPER_QUORUM).isSet()) {
 throw new InitializationException("Instance name and Zookeeper 
Quorum must be specified");
 }
 
-
-
+final KerberosCredentialsService kerberosService = 
context.getProperty(KERBEROS_CREDENTIALS_SERVICE).asControllerService(KerberosCredentialsService.class);
 final String instanceName = 
context.getProperty(INSTANCE_NAME).evaluateAttributeExpressions().getValue();
 final String zookeepers = 
context.getProperty(ZOOKEEPER_QUORUM).evaluateAttributeExpressions().getValue();
-final String accumuloUser = 
context.getProperty(ACCUMULO_USER).evaluateAttributeExpressions().getValue();
+authType = AuthenticationType.valueOf( 
context.getProperty(AUTHENTICATION_TYPE).getValue());
+AuthenticationToken token;
 
-final AuthenticationType type = AuthenticationType.valueOf( 
context.getProperty(AUTHENTICATION_TYPE).getValue() );
+final Properties clientConf = new Properties();
+clientConf.setProperty("instance.zookeepers", zookeepers);
+clientConf.setProperty("instance.name", instanceName);
 
+switch(authType){
+case PASSWORD:
+final String accumuloUser = 
context.getProperty(ACCUMULO_USER).evaluateAttributeExpressions().getValue();
 
+token = new 
PasswordToken(context.getProperty(ACCUMULO_PASSWORD).getValue());
 
-final 

[GitHub] [nifi-minifi-cpp] aminadinari19 commented on a change in pull request #1040: MINIFICPP-1329- Fix implementation and usages of string to bool

2021-04-07 Thread GitBox


aminadinari19 commented on a change in pull request #1040:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1040#discussion_r608365026



##
File path: extensions/mqtt/processors/AbstractMQTTProcessor.cpp
##
@@ -146,7 +148,7 @@ void AbstractMQTTProcessor::onSchedule(const 
std::shared_ptr (this), 
connectionLost, msgReceived, msgDelivered);

Review comment:
   Yeah it was the C-style cast. I removed casting from here as Feri said 
implicit conversion was enough in this case.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [nifi-minifi-cpp] aminadinari19 commented on a change in pull request #1040: MINIFICPP-1329- Fix implementation and usages of string to bool

2021-04-07 Thread GitBox


aminadinari19 commented on a change in pull request #1040:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1040#discussion_r608365026



##
File path: extensions/mqtt/processors/AbstractMQTTProcessor.cpp
##
@@ -146,7 +148,7 @@ void AbstractMQTTProcessor::onSchedule(const 
std::shared_ptr (this), 
connectionLost, msgReceived, msgDelivered);

Review comment:
   Yeah it was the C-style cast. I removed casting from here as Feri said 
implicit conversion was enough.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org