dear sir??
      i am using rsyslog 7.2.4
      when i use default template to put message into mongodb??time field is 
ISODate format??
         {........... "time" : ISODate("2013-01-05T06:31:16Z") .........}


      but when i use my own template to put message into mongodb??time field is 
string format??
         {.........."time" : "2013-01-05T14:24:52+08:00".....}


      my template is:


template(name="myBSON" type="string" string="%hostname%, 
%timereported:::date-rfc3339:time%, %msg%, 
%syslogfacility-text::::syslogfacility_text%, 
%syslogseverity-text::::syslogseverity_text%, %syslogseverity%, %programname%, 
%procid%, %fromhost-ip::::fromhost_ip%")


module (load="ommongodb")
*.* action(type="ommongodb" server="127.0.0.1" db="9fangit" 
collection="rsyslog" template="myBSON")



      my question is??
      How can i put message into mongodb with isodate format for time field 
when i use my own template??




------------------
????
li.wang
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of 
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE 
THAT.

Reply via email to