You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@nifi.apache.org by sally <sa...@gmail.com> on 2017/11/17 10:49:13 UTC
nifi: how to convert many file data into one file?
I want to get more than 20000 flowfile from hdfs and reunit them into one
flowfile ( i mean i want to get data from these files (they are in xml
format) and input it into variable named content ,then when i finish this
process i want to serilize xml in a way that all this data will be enrolled
inside ... tag)
--
Sent from: http://apache-nifi-users-list.2361937.n4.nabble.com/
Re: nifi: how to convert many file data into one file?
Posted by Mike Thomsen <mi...@gmail.com>.
Just use ExecuteScript and the Groovy MarkupBuilder/StreamingMarkupBuilder
APIs. There is plenty of documentation on the latter out there with good
samples. Depending on how much XML data there is, you'll probably need to
use the StreamingMarkupBuilder and have it write to a temp file. One
caveat: those two Groovy classes have their own use cases and slightly
different APIs that prevent you from copying and pasting code for one and
using it on the other.
On Fri, Nov 17, 2017 at 5:49 AM, sally <sa...@gmail.com>
wrote:
> I want to get more than 20000 flowfile from hdfs and reunit them into one
> flowfile ( i mean i want to get data from these files (they are in xml
> format) and input it into variable named content ,then when i finish this
> process i want to serilize xml in a way that all this data will be enrolled
> inside ... tag)
>
>
>
> --
> Sent from: http://apache-nifi-users-list.2361937.n4.nabble.com/
>