refaelos
(Refael Dakar)
June 27, 2015, 11:30am
1
Hey,
I'm transferring multiple events into ES using LS. For every event, i'm creating a timeStamp according to a milliseconds field:
date {
match => [ "saveTime", "UNIX_MS" ]
}
Many events succeed but every once in a while LS just stops and I see this error:
...
:message=>"Exception in filterworker", "exception"=>#<ArgumentError: comparison of String with 1413763200000 failed>
...
Why does it happen?
refaelos
(Refael Dakar)
June 27, 2015, 11:44am
2
The full backtrace is:
"backtrace"=>["org/jruby/RubyComparable.java:168:in `<'", "org/jruby/RubyString.java:1874:in `<'", "(eval):164:in `cond_func_5'", "org/jruby/RubyArray.java:1613:in `each'", "(eval):162:in `cond_func_5'", "(eval):95:in `filter_func'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/logstash-core-1.5.0-java/lib/logstash/pipeline.rb:219:in `filterworker'", "/opt/logstash/vendor/bundle/jruby/1.9/gems/logstash-core-1.5.0-java/lib/logstash/pipeline.rb:156:in `start_filters'"], :level=>:error, :file=>"logstash/pipeline.rb", :line=>"231", :method=>"filterworker"
So I guess it happens on flush.
refaelos
(Refael Dakar)
June 28, 2015, 1:16pm
3
Solved this by adding another filter:
mutate {
convert => { "saveTime" => "integer" }
}
1 Like
jpizzle
(JonathanP)
February 18, 2016, 10:26pm
4
Thanks! Rocked it. Appreciate the followup refaelos!