Logstash http input fails

I am trying to api call logstash by using http input but when I send request I got error below

Here is my config file

input {
  http {
		port =>"2020"

output {
  elasticsearch {
    hosts => [""]
	index => "abcfront"

and here is my error log

[2022-08-17T13:32:55,710][WARN ][logstash.outputs.abc][main][97e0a2c5c534e1761e20eb9cd124dad3c5f10f0019d8b023763a076f395d45b9] Could not index event to asd. {:status=>400, :action=>["index", {:_id=>nil, :_index=>"abcfront", :routing=>nil, :_type=>"_doc"}, #<LogStash::Event:0x6e90b9f6>], :response=>{"index"=>{"_index"=>"abcfront", "_type"=>"_doc", "_id"=>"VCxdq4IBhV40gealAsF8", "status"=>400, "error"=>{"type"=>"mapper_parsing_exception", "reason"=>"object mapping for [host] tried to parse field [host] as object, but found a concrete value"}}}}

Hello there!
I think you should consider changing to your node IP address.


See this thread.

I solve this issue by removing host field from my event in logstash

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.