Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(lambda): bump @aws-lambda-powertools/tracer from 1.18.1 to 2.13.0 in /lambdas #629

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

dependabot[bot]
Copy link

@dependabot dependabot bot commented on behalf of github Jan 20, 2025

Bumps @aws-lambda-powertools/tracer from 1.18.1 to 2.13.0.

Release notes

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

v2.13.0

Summary

In this release we fixed a bug in Tracer that prevented Fetch API requests from propagating the parent trace. We also improved the Parser experience by adding a helper to easily write Zod schemas for DynamoDB data structures.

⭐️ Thanks to @​arnabrahman for their contributions to this release!

Full traces when working with Fetch API

Docs

Requests made with the global fetch module now adds X-Ray trace info to requests in the X-Amzn-Trace-Id header. This allows X-Ray to construct a full trace that includes upstream and downstream nodes.

Zod schemas with Amazon DynamoDB Attributes

Docs

You can now easily extend DynamoDB Stream schemas with your own payloads using the new DynamoDBMarshalled helper. This helper lets you focus on your schemas while we handle unmarshalling data from DynamoDB Attribute format to the native format before Zod parses the payload.

carbon

Changes

  • test(parser): refactor appsync schema tests (#3388) by @​svozza
  • chore(deps): bump zgosalvez/github-actions-ensure-sha-pinned-actions from 3.0.17 to 3.0.18 (#3430) by @​dependabot
  • chore(deps): bump actions/upload-artifact from 4.4.3 to 4.5.0 (#3437) by @​dependabot

🌟New features and non-breaking changes

  • feat(parser): DynamoDBMarshalled helper to parse DynamoDB data structure (#3442) by @​arnabrahman

🌟 Minor Changes

📜 Documentation updates

... (truncated)

Changelog

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

2.13.0 (2025-01-14)

Bug Fixes

  • tracer: forward X-Amzn-Trace-Id header when instrumenting fetch (#3470) (4eb3e2d)

Features

  • parser: DynamoDBMarshalled helper to parse DynamoDB data structure (#3442) (e154e58)

2.12.0 (2024-12-17)

Bug Fixes

Features

  • logger: change selected method visibility to protected (#3377) (93a19a5)
  • metrics: disable metrics with POWERTOOLS_METRICS_DISABLED (#3351) (7e8578e)
  • metrics: warn when overwriting dimension (#3352) (12f3e44)
  • parser: Add appsync resolver event Zod schemas (#3301) (318f34b)
  • parser: add schema for DynamoDB - Kinesis Stream event (#3328) (a8dfa74)

2.11.0 (2024-11-20)

Bug Fixes

  • metrics: skip empty string dimension values (#3319) (924d49d)
  • parser: add aws region to kinesis event (#3260) (246f132)
  • parser: event type literal for selfManagedKafka (#3325) (5350afe)
  • parser: fix cause errors nested structure (#3250) (1ff97cb)

Features

  • batch: Async Processing of Records for for SQS Fifo (#3160) (e73b575)

... (truncated)

Upgrade guide

Sourced from @​aws-lambda-powertools/tracer's upgrade guide.


title: Upgrade guide description: Guide to update between major Powertools for AWS Lambda (TypeScript) versions

End of support v1

!!! warning "On March 13th, 2024, Powertools for AWS Lambda (TypeScript) v1 entered maintenance mode, and has reached End-of-Life on September 1st, 2024. If you are still using v1, we strongly recommend you to upgrade to the latest version."

Given our commitment to all of our customers using Powertools for AWS Lambda (TypeScript), we will keep npm v1 releases and documentation 1.x versions to prevent any disruption.

Migrate from v1 to v2

V2 is focused on official support for ESM (ECMAScript modules). We've made other minimal breaking changes to make your transition to v2 as smooth as possible.

Quick summary

Area Change Code change required
ESM support Added ESM support via dual CommonJS and ESM bundling, enabling top-level await and tree-shaking. -
Middy.js Updated import path for Middy.js middlewares to leverage subpath exports - i.e. @aws-lambda-powertools/tracer/middleware. Yes
Types imports Updated import path for TypeScript types to leverage subpath exports - i.e. @aws-lambda-powertools/logger/types. Yes
Logger Changed log sampling to dynamically switch log level to DEBUG on a percentage of requests. -
Logger Updated custom log formatter to include standard as well as persistent keys. Yes
Logger Removed ContextExamples from @aws-lambda-powertools/commons package. Yes
Logger and Tracer Removed deprecated createLogger and createTracer helper functions in favor of direct instantiation. Yes

First steps

Before you start, we suggest making a copy of your current working project or create a new git branch.

  1. Upgrade Node.js to v18 or higher, Node.js v20 is recommended.
  2. Ensure that you have the latest Powertools for AWS Lambda (TypeScript) version via Lambda Layer or npm.
  3. Review the following sections to confirm whether they apply to your codebase.

ESM support

With support for ES Modules in v2, you can now use import instead of require syntax.

This is especially useful when you want to run asynchronous code during the initialization phase by using top-level await.

import { getSecret } from '@aws-lambda-powertools/parameters/secrets';
// This code will run during the initialization phase of your Lambda function
const myApiKey = await getSecret('my-api-key', { transform: 'json' });
export const handler = async (_event: unknown, _context: unknown) => {
</tr></table>

... (truncated)

Commits
  • 1aade41 chore(ci): bump version to 2.13.0 (#3471)
  • 0ef15a7 test(parser): refactor appsync schema tests (#3388)
  • 4eb3e2d fix(tracer): forward X-Amzn-Trace-Id header when instrumenting fetch (#3470)
  • e154e58 feat(parser): DynamoDBMarshalled helper to parse DynamoDB data structure (#...
  • 149e17f refactor(metrics): swap isDate for instanceof Date (#3462)
  • 1d1e2f9 chore(deps-dev): bump lint-staged from 15.2.11 to 15.3.0 (#3460)
  • 26d6488 chore(deps): bump the typescript group across 1 directory with 4 updates (#3446)
  • bb74ef5 chore(deps): bump the aws-sdk-v3 group across 1 directory with 11 updates (#3...
  • 7a07ccb chore(deps): bump @​types/node from 22.10.2 to 22.10.5 (#3456)
  • bee2df2 chore(deps): bump @​aws-cdk/cli-lib-alpha to 2.174.1-alpha.0 (#3458)
  • Additional commits viewable in compare view
Maintainer changes

This version was pushed to npm by aws-powertools-bot, a new releaser for @​aws-lambda-powertools/tracer since your current version.


Dependabot compatibility score

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 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 <dependency name> 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)

Bumps [@aws-lambda-powertools/tracer](https://github.com/aws-powertools/powertools-lambda-typescript) from 1.18.1 to 2.13.0.
- [Release notes](https://github.com/aws-powertools/powertools-lambda-typescript/releases)
- [Changelog](https://github.com/aws-powertools/powertools-lambda-typescript/blob/main/CHANGELOG.md)
- [Upgrade guide](https://github.com/aws-powertools/powertools-lambda-typescript/blob/main/docs/upgrade.md)
- [Commits](aws-powertools/powertools-lambda-typescript@v1.18.1...v2.13.0)

---
updated-dependencies:
- dependency-name: "@aws-lambda-powertools/tracer"
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code labels Jan 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants