Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Parsing message in NIFI

Solved Go to solution

Parsing message in NIFI

Rising Star

I need to parse location sensor messages; instead of processing in Spark, i would like to try out in NIFI (HDF2.0), the messages are simple . I just need to split the content with ',' and then tranform it.

I couldn't find the right process in NiFi, can you please help me on that?

Thanks,

SJ

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: Parsing message in NIFI

I'd suggest checking out the SplitContent processor[1]. Just set "Byte Sequence" to what you want to split it on (','). Then you can process each split as it's own FlowFile.

[1] https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi.processors.standard.SplitContent/i...

View solution in original post

3 REPLIES 3
Highlighted

Re: Parsing message in NIFI

I'd suggest checking out the SplitContent processor[1]. Just set "Byte Sequence" to what you want to split it on (','). Then you can process each split as it's own FlowFile.

[1] https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi.processors.standard.SplitContent/i...

View solution in original post

Highlighted

Re: Parsing message in NIFI

Rising Star

Hi ,

Thanks for the help. I applied the "splitContent" and now it split the message by ','.

SJ

Highlighted

Re: Parsing message in NIFI

Rising Star

I lost my project and now again when i want to split the text based on the ',' doesn't work, Not sure if in the version of nifi(1.1) this feature has been changed. Please find my config in the attachment. It gives me an error that ',' is not a valid hex content.

untitled.png

thanks, SJ

Don't have an account?
Coming from Hortonworks? Activate your account here