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.

how to send attribute from nifi

how to send attribute from nifi

Explorer

confused related to filed ...my web app made in python ..when i have to update new attribute from python i will just write alarm.attribut[attribute_name]=[attribute_value]...same thing i want to update from nifi ...for this i used invoke http processor and attribute end point in Remote url with PUT method 

"https://localhost:8080/api/alarm/<alarm_id>/attributes"

and i have used two processors updateAttribute and AttributeTojson

i think i have done mistake in dynamic property of updateAttribute processor -

propertyname -attributes

propertyvalue - $.{alarm.attributes['attribute_name'] = 'attribute_value'} or ${alarm.attributes['attribute_name'] = 'attribute_value'} 

and in AttributeTojson in Attribute List - id,attributes

please suggest me the right way of passing new attribute. 

@stevenmatison 

 

thanks 

2 REPLIES 2
Highlighted

Re: how to send attribute from nifi

@renuu  Can you update the post above with screenshot of your UpdateAttribute and InvokeHttp settings?  Also let us see the content of the flowfile you are sending to UpdateAttribute.

 

 

It sounds like you have the right method, but maybe need some adjustment in those settings.  I will be able to comment better once I can see your screenshots.

 


 


If this answer resolves your issue or allows you to move forward, please choose to ACCEPT this solution and close this topic. If you have further dialogue on this topic please comment here or feel free to private message me. If you have new questions related to your Use Case please create separate topic and feel free to tag me in your post.  


 


Thanks,



Steven

Highlighted

Re: how to send attribute from nifi

Explorer

updateAttribute

renuu_0-1591187413227.png

Attributetojson

renuu_1-1591187455654.png

invoke http

renuu_2-1591187552306.png

 

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