From d9dfc643d425cba0038b385e7a10a2f1201bd61f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Dec 2024 16:38:08 +0000 Subject: [PATCH] Upgrade: [dependabot] - bump @aws-lambda-powertools/logger from 2.11.0 to 2.12.0 (#262) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bumps [@aws-lambda-powertools/logger](https://github.com/aws-powertools/powertools-lambda-typescript) from 2.11.0 to 2.12.0.
Release notes

Sourced from @​aws-lambda-powertools/logger's releases.

v2.12.0

Summary

In this release we have made the Logger class more extensible, added POWERTOOLS_METRICS_DISABLED to control metrics output in non production environment, and added AppSyncResolverSchema and KinesisDynamoDBStreamSchema to the parser utility.

⭐️ Thanks to @​zirkelc and @​svozza for their contributions to this release!

Logger class is now more extensible

You can now overwrite the Logger methods createAndPopulateLogItem, printLog, processLogItem, which were private before. This allows you to extend the Logger and add new functionality, i.e. implement your own message buffer.

Metrics utility improvements

You can now set POWERTOOLS_METRICS_DISABLED to control the metrics output. This is useful when you don't want to emit metrics in a non-production environment. When POWERTOOLS_DEV is enabled, the metrics are also suppressed, but you can always explicitly enable it with POWERTOOLS_METRICS_DISABLED .

We have also added a warning message when you overwrite a dimension with the same key, which will help you to troubleshoot unintentional changes:

import { Metrics } from '@aws-lambda-powertools/metrics';

const metrics = new Metrics({ singleMetric: true });

metrics.addDimension('test', 'foo');
metrics.addDimension('test', 'bar'); // "bar" replaces "foo"

// warning: Dimension "test" has already been added. The previous value will be overwritten.

New schema for AppSync and DynamoDB events

You can now use AppSyncResolverSchema and AppSyncResolverBatchSchema to parse AppSync Lambda resolver event.

We have also added KinesisDynamoDBStreamSchema to validate the event from the invocation chain of DynamoDB, Kinesis and Lambda, which are slightly different compared to direct DynamoDB Streams invocations, see more details in #3193.

Changes

🌟New features and non-breaking changes

... (truncated)

Changelog

Sourced from @​aws-lambda-powertools/logger's changelog.

2.12.0 (2024-12-17)

Bug Fixes

Features

Commits

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=@aws-lambda-powertools/logger&package-manager=npm_and_yarn&previous-version=2.11.0&new-version=2.12.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) ---
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- package-lock.json | 18 +++++++++--------- package.json | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/package-lock.json b/package-lock.json index abe2ed4..6f5db48 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,7 @@ "version": "1.0.0", "license": "MIT", "dependencies": { - "@aws-lambda-powertools/logger": "^2.11.0", + "@aws-lambda-powertools/logger": "^2.12.0", "@middy/core": "^5.5.1", "conventional-changelog-eslint": "^6.0.0" }, @@ -42,20 +42,20 @@ } }, "node_modules/@aws-lambda-powertools/commons": { - "version": "2.11.0", - "resolved": "https://registry.npmjs.org/@aws-lambda-powertools/commons/-/commons-2.11.0.tgz", - "integrity": "sha512-gtiBeUSyg4VcL4qra5G4AwuOl7CNF6g0oDasAS5KxkEi8IhTku6S7vJTpQ82+12oviwKBD+w27yEcGQmSw5xdg==" + "version": "2.12.0", + "resolved": "https://registry.npmjs.org/@aws-lambda-powertools/commons/-/commons-2.12.0.tgz", + "integrity": "sha512-DCrnMzI6oilGO9qY47DraS2SL5QOeofiB/U0PT4ygko2mgyF7Zxxg62nIYi6uqLxlVt9fRrBth1MPtOFO1wqzg==" }, "node_modules/@aws-lambda-powertools/logger": { - "version": "2.11.0", - "resolved": "https://registry.npmjs.org/@aws-lambda-powertools/logger/-/logger-2.11.0.tgz", - "integrity": "sha512-40wST/S644ngwadp7Kk70Rgvh35yQ0R3HqFKxAtlBxQNAGsqxQtjJeBUg/KQDKUhE1IZH0ahXyEN3B7rSxPn0Q==", + "version": "2.12.0", + "resolved": "https://registry.npmjs.org/@aws-lambda-powertools/logger/-/logger-2.12.0.tgz", + "integrity": "sha512-dmIwkF8GeS45A/KR6bHrODJnfFwwoi1o5P22DaoyRy5Ty/wzEDHR0LJQJnFkc7iuzxCn8Mb0bpuZbwOaHuvo7w==", "dependencies": { - "@aws-lambda-powertools/commons": "^2.11.0", + "@aws-lambda-powertools/commons": "^2.12.0", "lodash.merge": "^4.6.2" }, "peerDependencies": { - "@middy/core": "4.x || 5.x" + "@middy/core": "4.x || 5.x || 6.x" }, "peerDependenciesMeta": { "@middy/core": { diff --git a/package.json b/package.json index 43f0d53..1f859f6 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ "typescript": "^5.7.2" }, "dependencies": { - "@aws-lambda-powertools/logger": "^2.11.0", + "@aws-lambda-powertools/logger": "^2.12.0", "@middy/core": "^5.5.1", "conventional-changelog-eslint": "^6.0.0" },