Method: Fluent::Plugin::Output#get_placeholders_time
- Defined in:
- lib/fluent/plugin/output.rb
#get_placeholders_time(str) ⇒ Object
it’s not validated to use timekey larger than 1 day
770 771 772 773 774 775 776 777 |
# File 'lib/fluent/plugin/output.rb', line 770 def get_placeholders_time(str) base_str = TIMESTAMP_CHECK_BASE_TIME.strftime(str) TIME_KEY_PLACEHOLDER_THRESHOLDS.each do |triple| sec = triple.first return triple if (TIMESTAMP_CHECK_BASE_TIME + sec).strftime(str) != base_str end nil end |