lib/fluent/plugin/out_mqtt_buf.rb in fluent-plugin-mqtt-io-0.0.2 vs lib/fluent/plugin/out_mqtt_buf.rb in fluent-plugin-mqtt-io-0.0.3

- old
+ new

@@ -21,10 +21,10 @@ # # NOTE! This method is called by internal thread, not Fluentd's main thread. So IO wait doesn't affect other plugins. def write(chunk) json = json_parse(chunk.read) $log.debug "#{json[0]}, #{format_time(json[1])}, #{json[2]}" - @connect.publish(rewrite_tag(json[0]), (json[2].merge(@time_key => format_time(json[1]))).to_json) + @connect.publish(rewrite_tag(json[0]), (json[2].merge(timestamp_hash(json[1]))).to_json) $log.flush end end end