Created on 08-20-2020 06:39 AM - last edited on 08-20-2020 01:11 PM by cjervis
Input to my Nifi flow is from CDC-> Kafka
I am using ConsumeKafka processor and in the flowfile contant I have list of columns on of a table on which CDC is enabled, Based on a flag present in my flowfile-content I am getting all the column values whihc were updated in the form of an array, I am storing this array in a attribute
ex: myAttr:[123,456,789]
For each flowfile this attributes is getting generated.
Now, I have a static array which contains a list of allowed keys(this is not generated from flow file, its something i am using to check the values in my attribute)
ex: AllowedKeys:[111,222,333,123,456,789]
I am trying to see if the values inside my attribute "myAttr" contains only the allowed keys
if all the values in myattr is present in AllowedKeys then i want to route it to success otherwise to failure
Please let me know how can i achieve this(preferably without ExecuteScript or custom processor)
Created 08-21-2020 12:43 AM
Hi, this should work for you : https://nifi.apache.org/docs/nifi-docs/html/expression-language-guide.html#alldelineatedvalues
Hope this helps. If the comment helps you to find a solution or move forward, please accept it as a solution for other community members.
Created 08-24-2020 04:50 AM
Tried with alldelineatedvalues but its not working
Can you share if you have any flow in which it worked for you
Created 08-25-2020 03:50 AM
Hi...extremely sorry for the comment before. i thought it should work without trying it out first. I looked at it again and it seems its not possible to do it without a script.