Member since
07-30-2019
3399
Posts
1621
Kudos Received
1001
Solutions
My Accepted Solutions
| Title | Views | Posted |
|---|---|---|
| 487 | 11-05-2025 11:01 AM | |
| 376 | 11-05-2025 08:01 AM | |
| 607 | 11-04-2025 10:16 AM | |
| 746 | 10-20-2025 06:29 AM | |
| 886 | 10-10-2025 08:03 AM |
12-23-2019
09:55 PM
@MattWho , Thank you for the details. I can understand your point that same file cannot be accessed across cluster nodes. But, I am using Nifi is single node (without cluster) and was thinking that this should work. Yes, i do use "Update Attribute" with the below file name conventions. This generates separate flow file for every message. I am trying to have this as one single file per node. ${filename:replace(${filename},"FileName_"):append(${now():format("yyyy-MM-dd-HH-mm-ss")})}.Json Thank you
... View more
12-23-2019
10:12 AM
@Siraj Does your ConsumeMQTT processor produce all output FlowFIles with the same Filename? Your MergeContent processor will merge if both configured min settings are satisfied at the end of execution. If you have your MergeContent processor configured to run as fast as possible (run schedule set to 0 sec default). It may upon execution only see one FlowFile on incoming connection at that moment in time and put only one FlowFile in a bin and merge just that one FlowFile since you set your min num entries to "1". I suggest you edit your MergeContent as follows: 1. Configure "Correlation Attribute Name" to "filename". 2. Perhaps increase your min setting from 1 to some higher value. 3. Always set "Max Bin Age". (This is your forced merge property, it will force a bin to merge even if it has not reach both min values within this configured amount of time.) 4. Make sure you have enough bins to accommodate the expected number of unique filenames plus 1 extra. (If all bins have allocated FlowFiles to them and the next FlowFile cannot be added to an existing bin, the oldest bin will be forced to merge to free a bin). The NiFi putFile processor does not support append. Append actions can cause all kinds of issue especially with a NiFi cluster where the target directory of the putFile is mounted to all the NiFi nodes. You can't have multiple nodes trying to write/append to the same file at the same time. My suggestion would be to use the UpdateAttribute processor before your putFile to modify the filename attribute. Perhaps prepend a uuid to the filename to ensure uniqueness across multiple files or NiFi nodes (if clustered). ${UUID()}-${filename} Hope this helps you, Matt
... View more
12-23-2019
09:48 AM
@Boenu You will need to configure your HandleHttpRequest processor with a SSL Context Service in order to encrypt data in transit being sent to this processor from a client. This of course then means you client needs to be able to at a minimum to trust the server certificate presented by this SSL context service in the TLS handshake. The truststore you use in the NiFi SSL Context Service will only need to contain the public cert for your client or complete certificate trust chain for your client if you have configured your HandleHttpRequest processor to "Need authentication" in the Client Authentication property. Mutual Authentication is not needed to ensure encryption of data in transit. Hope this helps, Matt
... View more
12-23-2019
09:40 AM
@Former Member This should not be happening unless you are clearing NiFi state between restarts or NiFi is having a state issue. When the listSFTP processor runs, it will record state so it does not list the same files more than once. If the Files being written to the SFTP server from which you are listing are not using dot rename as they are being written, it is possible your ListSFTP processor is listing them while they are still being written to. Since state is based off timestamps, a file still being written to will have its timestamp updated between executions of the listSFTP processor. This would result in the file being listed again. If the standard ssh dot rename method is not being used, you may need to "minimum File Age" property in listSFTP to make sure only files whose timestamp has not updated for X amount of time are listed. This of course depends on your version of NiFi being used since this property was introduced as part of https://issues.apache.org/jira/browse/NIFI-5977 There is also the possibility if you are using NiFi 1.8 you are hitting this known bug: https://issues.apache.org/jira/browse/NIFI-5849 If you found a solution that worked, please tae a moment to accept the solution to resolve this community question. Thank you, Matt
... View more
12-20-2019
07:29 AM
@saivenkatg55 NiFi musty be secured before you can use any form of authentication and authorization. Along with securing NiFi you can configure NiFi's login-identity-providers.xml to use the "ldap-provider" for user authentication. Here are some useful links: Securing NiFi: https://docs.cloudera.com/HDPDocuments/HDF3/HDF-3.4.1.1/nifi-authentication/content/nifi_authentication.html Setting up ldap-provider: https://docs.cloudera.com/HDPDocuments/HDF3/HDF-3.4.1.1/nifi-security/content/ldap_login_identity_provider.html Setting up authorization: https://docs.cloudera.com/HDPDocuments/HDF3/HDF-3.4.1.1/nifi-authorization/content/nifi_authorization.html Hope this helps, Matt
... View more
12-18-2019
06:19 AM
HI!! the problem was in CSVReader the decision was to change Schema Access Strategy after this manipulation everything began to work.
... View more
12-17-2019
08:51 PM
Thanks Matt for the quick response.
... View more
12-16-2019
11:48 AM
@JSJ Let's assume you have following directory structure: /nifi/test/AX1/ /nifi/test/AX2/ /nifi/test/XY1/ /nifi/test/XY2/ You would configure your listFile processor as follows: Hope this helps, Matt
... View more
12-15-2019
09:26 PM
Sure thanks. @MattWho. it works!
... View more
12-13-2019
07:02 AM
@fowler7878 You are correct that MonitorActivity can not be used to monitor on activity based on per month thresholds. Your use case is not one NiFi is designed to handle. NiFi is designed to work with FlowFiles and typically NiFi processor are not designed to return directory listings. Your use case may require you to build your own custom NiFi processor or perhaps your own custom script that your can execute via ExecuteStreamCommand or ExecuteScript processors where the script returns number of files in a target directory which you can then make notification routing decisions with. I was just trying to offers a builtin solution/suggestion while not exactly what you are looking for. Thank you, Matt
... View more