From 52cdf6f9fe2b3f4475e4c84c978e6c8b174596c5 Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Fri, 5 Jun 2020 16:06:52 +0000 Subject: [PATCH] fix(core): update --- package-lock.json | 14 +++++++------- package.json | 4 ++-- test/test.ts | 18 +++++++++++++++++- ts/logdna.classes.logmessage.ts | 3 ++- 4 files changed, 28 insertions(+), 11 deletions(-) diff --git a/package-lock.json b/package-lock.json index 7bed9d6..e3f0a94 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1280,11 +1280,11 @@ } }, "@pushrocks/smartlog-interfaces": { - "version": "2.0.9", - "resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartlog-interfaces/-/smartlog-interfaces-2.0.9.tgz", - "integrity": "sha512-JlVBHNjac0+VbTyigBqVXLsOWggmg9vONk8cofvfUmYq8QZ3XmEQlkljotjgn01ZA6aEQ4NmskRy0XSNcJl/Fw==", + "version": "2.0.15", + "resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartlog-interfaces/-/smartlog-interfaces-2.0.15.tgz", + "integrity": "sha512-C9AQGs0QI2xmcIbb2A32rg1rebHavpXGJ1LXBSLpSvctyrBppxWjut7kihgU5nqxYYw+Cr+wl5DA1pSIPQ1R0w==", "requires": { - "@apiglobal/typedrequest-interfaces": "^1.0.7" + "@apiglobal/typedrequest-interfaces": "^1.0.13" } }, "@pushrocks/smartlog-source-ora": { @@ -1744,9 +1744,9 @@ "integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==" }, "@types/node": { - "version": "14.0.9", - "resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-14.0.9.tgz", - "integrity": "sha512-0sCTiXKXELOBxvZLN4krQ0FPOAA7ij+6WwvD0k/PHd9/KAkr4dXel5J9fh6F4x1FwAQILqAWkmpeuS6mjf1iKA==" + "version": "14.0.11", + "resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-14.0.11.tgz", + "integrity": "sha512-lCvvI24L21ZVeIiyIUHZ5Oflv1hhHQ5E1S25IRlKIXaRkVgmXpJMI3wUJkmym2bTbCe+WoIibQnMVAU3FguaOg==" }, "@types/portscanner": { "version": "2.1.0", diff --git a/package.json b/package.json index 0bf158c..833ba41 100644 --- a/package.json +++ b/package.json @@ -17,13 +17,13 @@ "@gitzone/tstest": "^1.0.33", "@pushrocks/qenv": "^4.0.6", "@pushrocks/tapbundle": "^3.2.1", - "@types/node": "^14.0.9", + "@types/node": "^14.0.11", "tslint": "^6.1.2", "tslint-config-prettier": "^1.18.0" }, "dependencies": { "@pushrocks/lik": "^4.0.13", - "@pushrocks/smartlog-interfaces": "^2.0.9", + "@pushrocks/smartlog-interfaces": "^2.0.15", "@pushrocks/smartrequest": "^1.1.47", "@pushrocks/smartstring": "^3.0.18", "@pushrocks/taskbuffer": "^2.1.1" diff --git a/test/test.ts b/test/test.ts index d6ee664..c469526 100644 --- a/test/test.ts +++ b/test/test.ts @@ -26,6 +26,10 @@ tap.test('should create a standard log message', async () => { runtime: 'node', zone: 'shipzone' }, + correlation: { + id: '123', + type: 'none' + }, message: 'this is an awesome log message sent by the tapbundle test' }); }); @@ -49,7 +53,11 @@ tap.test('should send in order', async () => { runtime: 'node', zone: 'shipzone' }, - message: `this is an awesome log message sent by the tapbundle test #${i}` + message: `this is an awesome log message sent by the tapbundle test #${i}`, + correlation: { + id: '123', + type: 'none' + } }; testLogDnaAccount.sendSmartlogPackage(testSmartlogMessage); i++; @@ -67,6 +75,10 @@ tap.test('should send in order', async () => { runtime: 'node', zone: 'shipzone' }, + correlation: { + id: '123', + type: 'none' + }, message: `this is an awesome log message sent by the tapbundle test #${i}` }; testLogDnaAccount.sendSmartlogPackage(testSmartlogMessage2); @@ -83,6 +95,10 @@ tap.test('should send in order', async () => { runtime: 'node', zone: 'shipzone' }, + correlation: { + id: '123', + type: 'none' + }, message: `this is an awesome log message sent by the tapbundle test #${i}` }; testLogDnaAccount.sendSmartlogPackage(testSmartlogMessage3); diff --git a/ts/logdna.classes.logmessage.ts b/ts/logdna.classes.logmessage.ts index 113ec1c..6789330 100644 --- a/ts/logdna.classes.logmessage.ts +++ b/ts/logdna.classes.logmessage.ts @@ -71,7 +71,8 @@ export class LogdnaMessage { line: smartlogPackageArg.message, meta: { ...smartlogPackageArg.context, - logType: smartlogPackageArg.type + logType: smartlogPackageArg.type, + correlation: smartlogPackageArg.correlation }, env: smartlogPackageArg.context.environment, hostname: smartlogPackageArg.context.zone,