Hi, I have sample http input plugin and posting json data to this plugin. I want to copy the json body into another field in order to standardize the output format. Invalid jsons are going into message field. I followed this link - https://www.elastic.co/blog/introducing-logstash-input-http-plugin. This link says body will be deserialized and expanded to root.. Please suggest how to do.. Thanks.
input {
http {
host => "xxx" # default: 0.0.0.0
port => 8080 # default: 8080
}
}
filter {
grok {
match => { "[headers][request_uri]" => "/app/%{WORD:App}/env/%{WORD:Environment}/dc/%{WORD:DataCenter}" }
}
}
output {
kafka {
codec => json
bootstrap_servers => "xxx"
topic_id => "xx-topic"
}
}