I want to add a non-string type field A( long type or json type) to logstash output, and set it's value by another field B .
so i need to access the value of B.
almost all examples related to accessing field value are nested in a string as:
" the longitude is %{[geoip][location][0]}"
i want to get field value in it's original type, like json,
But in this particular case, do you really want to keep the original field (and duplicate the location data)? If not then perhaps the mutate filter's rename option is what you're really looking for.
thank you for quick reply
because in my log file, there are already country/city/region fields that thought more accuracy, so i need only lon_lat fields in geoip
rename option is very helpful
I have another question: is there any significant difference between mutate filter rename option and ruby filter in effeciency?
thank you!
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.