El mié., 5 ago. 2020 a las 8:22, David Lang via rsyslog (<[email protected]>) escribió: > > if I do > > set $!trusted!timestamp=$timegenerated; > > what I get is a low precision formatted timestamp > > if I then try to send this to a remote machine, $!trusted!timestamp contains > something like "Aug 4 20:00:01" so there is no ability to reformat the data > an > get a high precision timestamp > > is there any way to send a timestamp in a variable that can be formatted as > either a high or low precision string on the receiving end?
Not at the moment. IIRC (pretty sure), it requires considerate refactoring, as we do not have native date type support inside the variable/scripting subsystem. That said, we could possibly think about a function to convert a date string to a unix timestamp and then work on that one. Unfortunately, we lose the high precision part in that process. To work around that, we could carry it around as a second subsecond-only timestamp. It's all not very intuitive, unfortunately. Not sure if it is worth the effort. Rainer > > David Lang > _______________________________________________ > rsyslog mailing list > https://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. _______________________________________________ rsyslog mailing list https://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.

