Error: The setting `host` in plugin `elasticsearch` is obsolete and is no longer available. Please use the 'hosts' setting instead. You can specify multiple entries separated by comma in 'host:port' format

It explains it in the error - The settinghostin pluginelasticsearchis obsolete and is no longer available. Please use the 'hosts' setting instead.

Check the docs - https://www.elastic.co/guide/en/logstash/current/plugins-outputs-elasticsearch.html#plugins-outputs-elasticsearch-hosts