Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Delete ElasticSearch document using PutElasticsearchHttp

avatar
New Contributor

Hi,

I am trying to delete ES document using PutElasticsearchHttp.

I can query for the document but when I try to delete i get error message "Flowfile content is not valid json" I get the flowfile in XML format.

My identifier value is extracted as an attribute. This same attribute value can query ES and successfully fetch record I wanted to delete. This only fails when i add PutElasticsearchHttp process.

 

rookie_0-1595271513806.png

The above is my configuration.

Thanks

2 REPLIES 2

avatar
New Contributor

OK seems. I am doing something wrong here.

How do i delete a document from ElasticSearch using NiFi processor. I am using niFi version 1.8.0. Can i delete a document from ES with an attribute. without flow file? I ask this as I have already extracted attribute from file. I am going to use this as the identifier in NiFi processor.

avatar
New Contributor

I found solution to this. I have wrote a NiFi processor,easy for me to write processor in Java, to convert XML to JSON. I didn't go the XSLT path as my XMLs structure would be different.

Once i did convert the xml to json the delete function of the PutElasticsearchHttp processor worked.

Thanks