RuntimeTools / appmetrics

Node Application Metrics provides a foundational infrastructure for collecting resource and performance monitoring data for Node.js-based applications.
https://developer.ibm.com/open/node-application-metrics/
Apache License 2.0
977 stars 127 forks source link

Profiling events on z/OS contain bad data #525

Open matthewpwilson opened 6 years ago

matthewpwilson commented 6 years ago

Using version 3.1.3, profiling events on z/OS contain the following strange-looking function names, and empty filenames: { date: 0, functions: [ { self: 1, parent: 0, file: '', name: '(BrBoBoBt)', line: 0, count: 0 }, { self: 2, parent: 1, file: '', name: '(BpBrBoBgBrBaBm)', line: 0, count: 0 } ], time: 1525094177179 }

Each same is the same with some different IDs.

My test case produces much more sensible-looking data on Linux: "use strict"; let appmetrics = require('appmetrics'); let monitoring = appmetrics.monitor(); appmetrics.enable('profiling'); let http = require('http');

monitoring.on('profiling', function(data) { console.dir(data); });

let server = http.createServer(function (request, response) { response.write('Hello Monitored World!'); response.end(); });

console.log("Started test.js at " + (new Date())) server.listen(28225);

matthewpwilson commented 5 years ago

Trying this again with 4.0.1, I get some slightly more interesting data: { date: 0, functions: [ { self: 1, parent: 0, file: '', name: '(BrBoBoBt)', line: 0, count: 0 }, { self: 2, parent: 1, file: '', name: '(BpBrBoBgBrBaBm)', line: 0, count: 0 }, { self: 3, parent: 1, file: '^����^�?_?>\u0006��', name: '�/����|>��/�����?�%���', line: 45, count: 0 }, { self: 4, parent: 3, file: '^����^������\u0006��', name: '�/����|>�>�?�>�', line: 463, count: 0 }, { self: 5, parent: 4, file: '���>��\u0006��', name: '���', line: 136, count: 0 }, { self: 6, parent: 5, file: '���>��\u0006��', name: '�����?', line: 104, count: 0 }, { self: 7, parent: 6, file: '\u0007�\u0007��%�?>\u0007>?��\u0007/��������\u0005/��\u0005����\u0007>?��^?��%��\u0007/��������\u0007%��\u0007/�����\u0006��', name: '/���\u0006�/>?>`?�ˀ��>���?>�', line: 25, count: 0 }, { self: 8, parent: 7, file: '\u0007�\u0007��%�?>\u0007>?��\u0007/��������\u0005/��\u0005����\u0007�����^��?��%�>�\u0006��', name: '', line: 11, count: 0 }, { self: 9, parent: 8, file: '\u0007�\u0007��%�?>\u0007>?��\u0007/��������\u0005/��\u0005����\u0007>?��^?��%��\u0007/��_������\u0007%��\u0007/�����\u0006��', name: '>����>�', line: 100, count: 0 }, { self: 10, parent: 9, file: '^����^?���?�>�\u0006��', name: '|���?�>�(���/��\u0006�>�', line: 547, count: 0 }, { self: 11, parent: 10, file: '^����^������\u0006��', name: '����������?>��\u0006^��>���', line: 99, count: 0 }, { self: 12, parent: 11, file: '^����^?���?�>�\u0006��', name: '|���?�>�(���/��\u0006^��>���', line: 623, count: 0 }, { self: 13, parent: 12, file: '/�����\u0006��', name: '?', line: NaN, count: 96 } ], time: 1549988376679 }

Looks like there's probably an encoding issue there.