Member since
06-07-2017
3
Posts
0
Kudos Received
0
Solutions
06-08-2017
04:21 PM
@Matt Clarke Thanks, that answer my question. I have to move the contents of the flowFile B to its attributes, then fetch file C and parse it with more processors to set more attributes on the flowfile and finally restore the contents of the flowfile to what I saved to the attributes. Sound's like I'll go with a scripted processor instead, that will save a lot of headache for me 🙂
... View more
06-08-2017
02:18 PM
My description was unclear about an important point, I have updated it. Using the filename and path attributes of the flowfile I have to parse a file in the filesystem (or maybe query a database) to figure out what exactly needs to be done to the flow file contents.
... View more
06-08-2017
02:18 PM
I've got to watch a directory that includes subdirectories. Every file I receive in any subdirectory needs to be processed, but the details depend on the subdirectory and the filename, for some subdirectories I have to send an email, for others I have to execute one or more commands, store the file at a specific location, etc. Multiple actions per flow file are possible as well. I'm currently stuck on setting the attributes of the flowfile. My current plan is as follows: GetFile processor to watch the directory A creates flow file B InvokeScriptedProcessor uses attributes like B.filename and B.path to read and parse file C from the filesystem and updates the attributes, such as sftp server, email [addresses, subject and body] and commands to execute on flow file B RouteOnAttribute to the sftp workflow RouteOnAttribute to the email workflow RouteOnAttribute to the command execution workflow Is there a sane alternative to writing my own processor for task 2? The data file format of file C is pretty much up to me to define.
... View more
Labels:
- Labels:
-
Apache NiFi