You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nifi.apache.org by Sumanth Chinthagunta <xm...@gmail.com> on 2015/10/04 02:30:29 UTC

attributes to json

do we have attributes to json processor ? 
I am thinking to use it along with ExtractText where the matching data is stored in attributes. now I need to convert those attributes into json flowFile.
if we don’t have such processor, any ideas to use, existing processors to compose what I needed?
thanks
sumo 

Re: attributes to json

Posted by Joe Witt <jo...@gmail.com>.
Sumanth

This feature proposal captures where we think we'll be able to address
this desire for examples really well [1].

Thanks
Joe

[1] https://cwiki.apache.org/confluence/display/NIFI/Extension+and+Template+Registry

On Sun, Oct 4, 2015 at 10:47 PM, Sumanth Chinthagunta <xm...@gmail.com> wrote:
> Thanks Bryan.
> I guess I am not reading docs. wish we have more examples and blog posts for each existing processor.
> developers prefer to learn from examples then reading docs :-)
>
> I am trying to consolidate all flow examples on GitHub.
> I just finished a flow that connect NiFi to streaming dashboard:  https://github.com/xmlking/nifi-examples/tree/master/collect-stream-logs <https://github.com/xmlking/nifi-examples/tree/master/collect-stream-logs>
>
> sumo
>
>> On Oct 3, 2015, at 5:46 PM, Bryan Bende <bb...@gmail.com> wrote:
>>
>> Hello,
>>
>> You could use ReplaceText to build a new Json document from flow file
>> attributes. Something like...
>>
>> Replacement Text = { "myField" : "${attribute1}" }
>>
>> -Bryan
>>
>> On Saturday, October 3, 2015, Sumanth Chinthagunta <xm...@gmail.com>
>> wrote:
>>
>>> do we have attributes to json processor ?
>>> I am thinking to use it along with ExtractText where the matching data is
>>> stored in attributes. now I need to convert those attributes into json
>>> flowFile.
>>> if we don’t have such processor, any ideas to use, existing processors to
>>> compose what I needed?
>>> thanks
>>> sumo
>>
>>
>>
>> --
>> Sent from Gmail Mobile
>

Re: attributes to json

Posted by Sumanth Chinthagunta <xm...@gmail.com>.
Thanks Bryan. 
I guess I am not reading docs. wish we have more examples and blog posts for each existing processor.
developers prefer to learn from examples then reading docs :-)

I am trying to consolidate all flow examples on GitHub. 
I just finished a flow that connect NiFi to streaming dashboard:  https://github.com/xmlking/nifi-examples/tree/master/collect-stream-logs <https://github.com/xmlking/nifi-examples/tree/master/collect-stream-logs>

sumo

> On Oct 3, 2015, at 5:46 PM, Bryan Bende <bb...@gmail.com> wrote:
> 
> Hello,
> 
> You could use ReplaceText to build a new Json document from flow file
> attributes. Something like...
> 
> Replacement Text = { "myField" : "${attribute1}" }
> 
> -Bryan
> 
> On Saturday, October 3, 2015, Sumanth Chinthagunta <xm...@gmail.com>
> wrote:
> 
>> do we have attributes to json processor ?
>> I am thinking to use it along with ExtractText where the matching data is
>> stored in attributes. now I need to convert those attributes into json
>> flowFile.
>> if we don’t have such processor, any ideas to use, existing processors to
>> compose what I needed?
>> thanks
>> sumo
> 
> 
> 
> -- 
> Sent from Gmail Mobile


Re: attributes to json

Posted by Bryan Bende <bb...@gmail.com>.
Hello,

You could use ReplaceText to build a new Json document from flow file
attributes. Something like...

Replacement Text = { "myField" : "${attribute1}" }

-Bryan

On Saturday, October 3, 2015, Sumanth Chinthagunta <xm...@gmail.com>
wrote:

> do we have attributes to json processor ?
> I am thinking to use it along with ExtractText where the matching data is
> stored in attributes. now I need to convert those attributes into json
> flowFile.
> if we don’t have such processor, any ideas to use, existing processors to
> compose what I needed?
> thanks
> sumo



-- 
Sent from Gmail Mobile