@instana/aws-lambda
Advanced tools
Comparing version 1.76.0 to 1.77.0
{ | ||
"name": "@instana/aws-lambda", | ||
"version": "1.76.0", | ||
"version": "1.77.0", | ||
"description": "Instana tracing and monitoring for Node.js based AWS Lambdas", | ||
@@ -61,4 +61,4 @@ "author": { | ||
"dependencies": { | ||
"@instana/core": "^1.76.0", | ||
"@instana/serverless": "^1.76.0" | ||
"@instana/core": "^1.77.0", | ||
"@instana/serverless": "^1.77.0" | ||
}, | ||
@@ -75,3 +75,3 @@ "devDependencies": { | ||
}, | ||
"gitHead": "24579c129b79a1b9cf11137f20b68d5a7bee6a79" | ||
"gitHead": "8f685798cc6c1726be67a593e0e1f5dc36d16a1a" | ||
} |
@@ -9,2 +9,3 @@ 'use strict'; | ||
const triggers = require('./triggers'); | ||
const processResult = require('./process_result'); | ||
@@ -170,20 +171,5 @@ const { tracing } = instanaCore; | ||
} | ||
// capture HTTP errors | ||
if (result && typeof result === 'object' && result.statusCode) { | ||
if (typeof result.statusCode === 'number') { | ||
entrySpan.data.http = entrySpan.data.http || {}; | ||
entrySpan.data.http.status = result.statusCode; | ||
if (result.statusCode >= 500) { | ||
entrySpan.ec = entrySpan.ec ? entrySpan.ec + 1 : 1; | ||
entrySpan.data.lambda.error = entrySpan.data.lambda.error || `HTTP status ${result.statusCode}`; | ||
} | ||
} else if (typeof result.statusCode === 'string' && /^\d\d\d$/.test(result.statusCode)) { | ||
entrySpan.data.http = entrySpan.data.http || {}; | ||
entrySpan.data.http.status = parseInt(result.statusCode, 10); | ||
if (entrySpan.data.http.status >= 500) { | ||
entrySpan.ec = entrySpan.ec ? entrySpan.ec + 1 : 1; | ||
entrySpan.data.lambda.error = entrySpan.data.lambda.error || `HTTP status ${result.statusCode}`; | ||
} | ||
} | ||
} | ||
processResult(result, entrySpan); | ||
entrySpan.error = entrySpan.ec > 0; | ||
@@ -190,0 +176,0 @@ entrySpan.d = Date.now() - entrySpan.ts; |
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
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
32235
15
615
Updated@instana/core@^1.77.0
Updated@instana/serverless@^1.77.0