Class: LogStash::EpocNode

Inherits:
Object
  • Object
show all
Defined in:
lib/logstash/string_interpolation.rb

Instance Method Summary collapse

Instance Method Details

#evaluate(event) ⇒ Object

Raises:



84
85
86
87
88
# File 'lib/logstash/string_interpolation.rb', line 84

def evaluate(event)
  t = event.timestamp
  raise LogStash::Error, "Unable to format in string \"#{@format}\", #{LogStash::Event::TIMESTAMP} field not found" unless t
  t.to_i.to_s
end