backtrace-service
Advanced tools
Comparing version 3.4.0 to 3.4.1-alpha.1
@@ -1,2 +0,2 @@ | ||
import { BacktraceClientOptions, IBacktraceClientOptions } from 'backtrace-node'; | ||
import { BacktraceConfiguration } from '@backtrace/node'; | ||
import winston from 'winston'; | ||
@@ -16,3 +16,3 @@ export interface ILoggerOptions { | ||
static setLogger(logger: Logger): void; | ||
static initializeBacktrace(opts: BacktraceClientOptions | IBacktraceClientOptions): void; | ||
static initializeBacktrace(opts: BacktraceConfiguration): void; | ||
private static _logger; | ||
@@ -19,0 +19,0 @@ private readonly transportLevel; |
@@ -39,3 +39,3 @@ "use strict"; | ||
exports.Logger = void 0; | ||
var backtrace_node_1 = require("backtrace-node"); | ||
var node_1 = require("@backtrace/node"); | ||
var util_1 = __importDefault(require("util")); | ||
@@ -122,3 +122,3 @@ var winston_1 = __importStar(require("winston")); | ||
Logger.initializeBacktrace = function (opts) { | ||
if (!opts || !opts.endpoint) { | ||
if (!opts || !opts.url) { | ||
return; | ||
@@ -128,3 +128,3 @@ } | ||
logger.debug('Initializing backtrace-node integration'); | ||
var client = (0, backtrace_node_1.initialize)(opts); | ||
var client = node_1.BacktraceClient.initialize(opts); | ||
if (!client) { | ||
@@ -177,5 +177,4 @@ logger.debug('Cannot initialize Backtrace integration. Please verify Backtrace url'); | ||
this.log.apply(this, __spreadArray(['error', errorOrData], data, false)); | ||
var client = (0, backtrace_node_1.getBacktraceClient)(); | ||
if (client) { | ||
client.reportSync(exception, attributes); | ||
if (node_1.BacktraceClient.instance) { | ||
node_1.BacktraceClient.instance.send(exception, attributes); | ||
} | ||
@@ -182,0 +181,0 @@ }; |
/// <reference types="node" /> | ||
import { IBacktraceClientOptions } from 'backtrace-node'; | ||
import { BacktraceConfiguration } from '@backtrace/node'; | ||
import { IServiceDescriptor } from '..'; | ||
@@ -12,3 +12,3 @@ /** | ||
logger: ILoggerOptions; | ||
backtrace: IBacktraceClientOptions & IRemoteLogger; | ||
backtrace: BacktraceConfiguration & IRemoteLogger; | ||
ssl: ISslOptions | undefined; | ||
@@ -15,0 +15,0 @@ }; |
@@ -43,4 +43,4 @@ "use strict"; | ||
exports.BacktraceService = void 0; | ||
var node_1 = require("@backtrace/node"); | ||
var argparse_1 = require("argparse"); | ||
var backtrace_node_1 = require("backtrace-node"); | ||
var body_parser_1 = require("body-parser"); | ||
@@ -234,3 +234,3 @@ var compression_1 = __importDefault(require("compression")); | ||
identityManager.bypassProjectAccessCheck(res); | ||
client = (0, backtrace_node_1.getBacktraceClient)(); | ||
client = node_1.BacktraceClient.instance; | ||
if (!client) { | ||
@@ -241,3 +241,3 @@ return [2 /*return*/, res.status(400).send({ | ||
} | ||
return [4 /*yield*/, client.reportAsync('Service-test')]; | ||
return [4 /*yield*/, client.send('Service-test')]; | ||
case 1: | ||
@@ -244,0 +244,0 @@ _a.sent(); |
{ | ||
"name": "backtrace-service", | ||
"version": "3.4.0", | ||
"version": "3.4.1-alpha.1", | ||
"description": "Common tools for Backtrace Node services", | ||
@@ -32,5 +32,5 @@ "author": "Backtrace", | ||
"dependencies": { | ||
"@backtrace/node": "file:../backtrace-javascript/packages/node", | ||
"argparse": "^2.0.1", | ||
"axios": "^0.27.2", | ||
"backtrace-node": "^1.2.0", | ||
"body-parser": "^1.20.0", | ||
@@ -51,7 +51,7 @@ "compression": "^1.7.4", | ||
"@types/helmet": "0.0.48", | ||
"@types/jest": "^27.5.1", | ||
"@types/jest": "^29.5.3", | ||
"@types/mkdirp": "^1.0.2", | ||
"@types/node": "^17.0.35", | ||
"@types/supertest": "^2.0.12", | ||
"jest": "^27.5.1", | ||
"jest": "^29.6.2", | ||
"minimist": "^1.2.6", | ||
@@ -61,3 +61,3 @@ "nock": "^13.2.4", | ||
"supertest": "^6.2.3", | ||
"ts-jest": "^27.1.4", | ||
"ts-jest": "^29.1.1", | ||
"tslint": "^6.1.2", | ||
@@ -64,0 +64,0 @@ "typescript": "^4.6.4" |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
229842
3370
2
+ Added@backtrace/node@file:../backtrace-javascript/packages/node
- Removedbacktrace-node@^1.2.0
- Removedaxios@0.21.4(transitive)
- Removedbacktrace-node@1.2.0(transitive)
- Removedform-data@2.5.2(transitive)
- Removedjson-stringify-safe@5.0.1(transitive)
- Removednative-reg@0.3.6(transitive)
- Removednode-gyp-build@4.8.4(transitive)
- Removedsource-scan@1.0.1(transitive)
- Removedstreamsink@1.2.0(transitive)
- Removedtslib@1.14.1(transitive)