I tried to use "timezone" in Date filter, my issue is that the input date is already in GMT and I need this value with my localtime to extract the "hour of day" and "day of week".
I mean the opposite function, I read other topics where it says the only way is using Ruby code to do that.
Thanks for any advise
PD. I fixed the functions 'stfrtime' and I have the same error
It works, but I need to clarify to other people that checks this post using an example with ("-12:00") as parameter in Ruby code (I'm in Mexico and this post was wrote in May 14, 2019 at 16:00:01 localtime )
"message" => "2019-05-14 21:00:01", --- Datetime GMT/UTC in my log file
"@timestamp" => 2019-05-14T21:00:45.406Z, --- Datetime right now in UTC/GMT
"justtime" => 2019-05-15T04:00:01.000Z, --- "message" moved 7 hours to the future, Logstash is trying to put in GMT/UTC according their rules
"newtime" => "2019-05-14 16:00:01", --- "Justtime" less 12 hours to be in my localtime
"host" => "localhost.localdomain",
"@version" => "1",
"sequence" => 0
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.