Filebeat cannot parse and drop the logs when receives the different type of input. "RequestPort":"-" (it usually contains the long type number)
Error:
{\"type\":\"mapper_parsing_exception\",\"reason\":\"failed to parse field [msg.RequestPort] of type [long] in document with id 'DOCUMENT_ID'. Preview of field's value: '-'\",\"caused_by\":{\"type\":\"illegal_argument_exception\",\"reason\":\"For input string: \\\"-\\\"\"}}, dropping event!"
this looks like the target index in Elasticsearch doesn't have a well-defined mapping for the msg.RequestPort field. This caused Elasticsearch to guess it as long based on the first document it received, which contained that field. If you want to be able to ingest the string "-" as a valid value, you'd have to define the field to be of the keyword type in the index template that is applied to the index.
Yes, the set processor can set a value conditionally if the appropriate if property is given. In your case it could be something like (careful, untested ):
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.