This should give you a date field with the current date (in the local timezone):
filter {
ruby {
code => "
event['date'] = Time.now.strftime('%Y-%m-%d')
"
}
}
This should give you a date field with the current date (in the local timezone):
filter {
ruby {
code => "
event['date'] = Time.now.strftime('%Y-%m-%d')
"
}
}
© 2020. All Rights Reserved - Elasticsearch
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.