Closed saki7 closed 12 years ago
This is not fluent-plugin-mongo and to_msgpack problem. Ruby's Yajl and JSON convert Time related object into String object. The cause is this conversion rule in fluent-logger-ruby.
I close this issue.
I see. Thanks!
When you pass Ruby's date related objects (such as
Date
,Time
,DateTime
) toFluent::Logger#post
, out_mongo stores it as a plain string in mongodb. I think it must be stored as anISODate("...")
format, like the way usual timestamps are stored.My code:
Fluent::Logger.post('mytag', {text: 'foo', created_at: DateTime.now})
Results in:
Is this fluent-plugin-mongo's problem? Or is it
to_msgpack
related problem? I'm quite not sure, but it must be related with the serialization process.