0
0
Fork 0
mirror of https://github.com/netdata/netdata.git synced 2025-04-13 17:19:11 +00:00

fix windows logs 2 - do not renumber - append fields ()

do not renumber - append fields
This commit is contained in:
Costa Tsaousis 2025-02-13 14:25:21 +02:00 committed by GitHub
parent 6cf5176afe
commit bca67f21c4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 12 additions and 16 deletions

View file

@ -117,15 +117,12 @@ typedef enum __attribute__((__packed__)) {
NDF_ALERT_SUMMARY = 60,
NDF_ALERT_INFO = 61,
NDF_ALERT_NOTIFICATION_REALTIME_USEC = 62,
// NDF_ALERT_FLAGS,
NDF_STACK_TRACE = 63, // stack trace of the thread logging
NDF_REQUEST = 63, // the request we are currently working on
NDF_MESSAGE = 64, // the log message, if any
NDF_STACK_TRACE = 65, // stack trace of the thread logging
// put new items here
// leave the request URL and the message last
NDF_REQUEST = 64, // the request we are currently working on
NDF_MESSAGE = 65, // the log message, if any
// NEVER RENUMBER FIELDS - RENUMBERING BREAKS EXISTING WINDOWS MESSAGES
// terminator
_NDF_MAX,

View file

@ -707,15 +707,6 @@ __thread struct log_field thread_log_fields[_NDF_MAX] = {
.logfmt = "alert_notification_timestamp",
.logfmt_annotator = timestamp_usec_annotator,
},
[NDF_STACK_TRACE] = {
.journal = "ND_STACK_TRACE",
.eventlog = "StackTrace",
.logfmt = NULL,
},
// put new items here
// leave the request URL and the message last
[NDF_REQUEST] = {
.journal = "ND_REQUEST",
.eventlog = "Request",
@ -726,6 +717,13 @@ __thread struct log_field thread_log_fields[_NDF_MAX] = {
.eventlog = "Message",
.logfmt = "msg",
},
[NDF_STACK_TRACE] = {
.journal = "ND_STACK_TRACE",
.eventlog = "StackTrace",
.logfmt = NULL,
},
// put new items here
};
// --------------------------------------------------------------------------------------------------------------------

View file

@ -284,6 +284,7 @@ int main(int argc, const char **argv) {
" <data name=\"AlertNotificationTime\" inType=\"win:UnicodeString\"/> <!-- 62 (NDF_ALERT_NOTIFICATION_REALTIME_USEC) -->\r\n"
" <data name=\"Request\" inType=\"win:UnicodeString\"/> <!-- 63 (NDF_REQUEST) -->\r\n"
" <data name=\"Message\" inType=\"win:UnicodeString\"/> <!-- 64 (NDF_MESSAGE) -->\r\n"
" <data name=\"StackTrace\" inType=\"win:UnicodeString\"/> <!-- 65 (NDF_STACK_TRACE) -->\r\n"
" </template>\r\n"
" </templates>\r\n"
"\r\n"