Merge pull request #157 from karlvlam/gelf-timefix

GELF time precision should be millisecond level
This commit is contained in:
Gareth Jones 2013-09-17 14:04:49 -07:00
commit 093f693232

View File

@ -100,7 +100,7 @@ function gelfAppender (layout, host, port, hostname, facility) {
msg.short_message = msg.full_message;
msg.version="1.0";
msg.timestamp = msg.timestamp || new Date().getTime() / 1000 >> 0;
msg.timestamp = msg.timestamp || new Date().getTime() / 1000; // log should use millisecond
msg.host = hostname;
msg.level = levelMapping[loggingEvent.level || levels.DEBUG];
msg.facility = facility;