logstash - How do I exclude the "fingerprint" field from elasticsearch -


i'm using fingerprint filter in logstash create fingerprint field set document_id in elasticsearch output.

configuration follows:

filter {   fingerprint {     method => "sha1"     key => "key"   } }  output {   elasticsearch {     host => localhost     document_id => "%{fingerprint}"   } } 

this results in redundant fingerprint field in elasticsearch that's same value _id. how prevent redundant field being saved es?

if you're using logstash 1.5 or higher, can put field in metadata , not sent elasticsearch part of regular message.

example:

filter {   fingerprint {     ...     target => "[@metadata][fingerprint]"   } }  output {   elasticsearch {     ...     document_id => "%{[@metadata][fingerprint]}"   } } 

Comments

Popular posts from this blog

javascript - Karma not able to start PhantomJS on Windows - Error: spawn UNKNOWN -

Nuget pack csproj using nuspec -

c# - Display ASPX Popup control in RowDeleteing Event (ASPX Gridview) -