Access metadata from input elasticsearch


(Vilas Reddy Podduturi) #1

Hi,

I am using elasticsearch input plugin for copying index from one cluster to another. I would like to access document metadata like _type.
I want to modify the _type and store in target elasticsearch cluster with new name.
How can I do that?

Regards,
Vilas


(Mark Walkom) #2

What plugin are you using, can you provide a link?


(Vilas Reddy Podduturi) #3

https://www.elastic.co/guide/en/logstash/1.5/plugins-inputs-elasticsearch.html


(Mark Walkom) #4

If you just want to replace the type, do that in the output.
Otherwise you can use "%{[@metadata][_type]}".


(system) #5