Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]

Support Questions

Find answers, ask questions, and share your expertise
Announcements
Share your experience with Cloudera on G2 and get a $25 Amazon Gift card.
Hi, I'm CLEO! Something exciting is coming to the Community. Stay Tuned!

Split a flowfile by space character

avatar
New Contributor

I am wanted to split this txt file into separate flow files at the spaces.


I am very new to nifi and regex and am unsure of which processor and properties I will need.

 

For example:

 

srcip=10.10.10.10 timestamp=152532431 action="denied" logver=12 tz="UTC+0" logid="0000012" dstip=12.12.12.12

This snippet is part of a long line that I need to split up at the spaces

So here I would have 6 separate flow files.

 

Any help appreciated.

1 ACCEPTED SOLUTION

avatar
Master Mentor

@JamesE 

This is easy enough do using the splitContent processor:

Screen Shot 2020-01-17 at 4.33.56 PM.png

for the "Byte Sequence" property simply hit your spacebar to set a single space.

If you found this answer addressed your question, please take a moment to accept to resolve this thread.

 

Hope this helps,

Matt

View solution in original post

1 REPLY 1

avatar
Master Mentor

@JamesE 

This is easy enough do using the splitContent processor:

Screen Shot 2020-01-17 at 4.33.56 PM.png

for the "Byte Sequence" property simply hit your spacebar to set a single space.

If you found this answer addressed your question, please take a moment to accept to resolve this thread.

 

Hope this helps,

Matt