Skip to content

Commit 989ee66

Browse files
Upgrade: [dependabot] - bump @aws-lambda-powertools/logger from 2.18.0 to 2.19.0 (#334)
Bumps [@aws-lambda-powertools/logger](https://github.com/aws-powertools/powertools-lambda-typescript) from 2.18.0 to 2.19.0. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/aws-powertools/powertools-lambda-typescript/releases"><code>@​aws-lambda-powertools/logger</code>'s releases</a>.</em></p> <blockquote> <h2>v2.19.0</h2> <h2>Summary</h2> <p>We are excited to announce a new integration for Event Handler to work with <a href="https://docs.aws.amazon.com/appsync/latest/eventapi/event-api-welcome.html">AWS AppSync Events APIs</a>. This utility provides a structured way to handle AppSync real-time events through dedicated handler methods, automatic routing, and flexible configuration options.</p> <p>We have also improved the experience for customers who are using the log buffering feature in Logger with AWS Lambda’s Advanced Logging Controls (ALC) enabled by emitting a log when the ALC log level is less verbose than the log level in the buffering configuration, which prevents data loss.</p> <p>⭐ A big thank you to <a href="https://github.com/jorovipe97"><code>@​jorovipe97</code></a> and <a href="https://github.com/ConnorKirk"><code>@​ConnorKirk</code></a> for their contributions to this release!</p> <h3>New Event Handler for AppSync Events</h3> <blockquote> <p><a href="https://docs.powertools.aws.dev/lambda/typescript/latest/features/event-handler/appsync-events/">Docs</a></p> </blockquote> <p>The new <code>AppSyncEventsResolver</code> is designed to streamline working with AWS AppSync real-time APIs by:</p> <ul> <li>Handling publish and subscribe events with dedicated handler methods</li> <li>Routing events automatically based on namespace and channel patterns</li> <li>Supporting wildcard patterns for catch-all handlers</li> <li>Controlling event aggregation for batch processing</li> <li>Implementing graceful error handling</li> </ul> <h4>Handling publish events</h4> <p>You can register handlers for publish events using the onPublish method and specifying a pattern for the namespace and channels. This is useful when you want to modify payload content, persist the message in a database, or apply business logic and conditionally filter messages out.</p> <p><img src="https://github.com/user-attachments/assets/3a08a6e7-9c19-4da1-859c-eb4126720578" alt="carbon" /></p> <h4>Handling subscribe events</h4> <p>You can use the onSubscribe() method to process subscription requests before allowing clients to connect to specific channels. This enables authorization checks and subscription filtering based on client context or payload attributes, as well as subscription tracking, for example:</p> <p><img src="https://github.com/user-attachments/assets/3687ad4b-5364-42dd-8ab5-8813d506abe7" alt="carbon-2" /></p> <h4>Working with aggregated processing</h4> <p>You can use the <code>aggregate</code> parameter when registering an <code>onPublish</code> handler to process multiple events together as a batch. This is useful when you need to optimize database operations, or want to have full control over how the messages are processed.</p> <p><img src="https://github.com/user-attachments/assets/1fe3f3b4-74c8-4866-825b-40bbeb7f9a93" alt="carbon-3" /></p> <h4><code>AppSyncEventsResolver</code> FAQs</h4> <p><strong>Q: Can I handle different types of events from the same channel?</strong> <strong>A:</strong> Yes, you can register different handlers for publish and subscribe events on the same channel. <strong>Q: How does handler precedence work with wildcard patterns?</strong> <strong>A:</strong> More specific patterns take precedence over wildcards. For example, <code>/default/channel1</code> will be chosen over <code>/default/</code>, which will be chosen over <code>/</code>. <strong>Q: What happens when an exception occurs in my handler?</strong> <strong>A:</strong> With individual processing (aka <code>aggregate</code> disabled), the utility catches exceptions and includes them in the response for the specific event while still processing other events. You can also explicitly raise an UnauthorizedException exception to reject the entire request. <strong>Q: Does the order of async event processing matter?</strong> <strong>A:</strong> No, AppSync Events doesn't guarantee delivery order. As long as each response includes the original event ID, AppSync processes them correctly regardless of order. Because of this, when <code>aggregate</code> is disabled, we call your handlers all at once. <strong>Q: Can I process multiple events as a batch?</strong></p> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/aws-powertools/powertools-lambda-typescript/blob/main/CHANGELOG.md"><code>@​aws-lambda-powertools/logger</code>'s changelog</a>.</em></p> <blockquote> <h1><a href="https://github.com/aws-powertools/powertools-lambda-typescript/compare/v2.18.0...v2.19.0">2.19.0</a> (2025-04-24)</h1> <h3>Bug Fixes</h3> <ul> <li><strong>logger:</strong> warn customers when the ALC log level is less verbose than log buffer (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3834">#3834</a>) (<a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/04f64ce23716037d6684fd4f6859bb8df8743911">04f64ce</a>)</li> <li><strong>logger:</strong> warn only once on ALC log level mismatch (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3816">#3816</a>) (<a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/1e330b3f96f0ae9f18dd09e2856658b22dbfd930">1e330b3</a>)</li> <li><strong>parser:</strong> Make Kafka key property optional (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3855">#3855</a>) (<a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/68fa1eb66abf4ccdb2b4f3789862e2380b8340aa">68fa1eb</a>)</li> </ul> <h3>Features</h3> <ul> <li><strong>event-handler:</strong> AppSync Events resolver (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3858">#3858</a>) (<a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/01f8a687a0c033cdc5d55c50bc7e6d0566f485cb">01f8a68</a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/53f0e40f1b4cc9a7821f0d13346d4b4983853399"><code>53f0e40</code></a> chore(ci): bump version to 2.19.0 (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3859">#3859</a>)</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/01f8a687a0c033cdc5d55c50bc7e6d0566f485cb"><code>01f8a68</code></a> feat(event-handler): AppSync Events resolver (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3858">#3858</a>)</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/68fa1eb66abf4ccdb2b4f3789862e2380b8340aa"><code>68fa1eb</code></a> fix(parser): Make Kafka key property optional (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3855">#3855</a>)</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/28841fe65c499355843c16f625240916750fad1a"><code>28841fe</code></a> chore: update cdk output dir (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3854">#3854</a>)</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/114188cd2bf230c59570f5fa05c552cbe2ed6d3d"><code>114188c</code></a> docs: Update metrics docs to mention correct POWERTOOLS_METRICS_DISABLED vari...</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/316fee1c26752fa0c2254a9b0d5a69086eb9c647"><code>316fee1</code></a> chore(deps-dev): bump typedoc from 0.28.2 to 0.28.3 in the typescript group a...</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/10b78c4692c234cadbd96004d4797243575ce4cf"><code>10b78c4</code></a> chore(deps-dev): bump the vitest group across 1 directory with 2 updates (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3845">#3845</a>)</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/d43adc8de6ea65ea22eca3d9445a10efc49c4fa9"><code>d43adc8</code></a> chore(deps-dev): bump zod from 3.24.2 to 3.24.3 (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3839">#3839</a>)</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/5e00d45a7ea94487c708c921c741b8affbcef969"><code>5e00d45</code></a> chore(deps): bump the aws-cdk group across 1 directory with 3 updates (<a href="https://redirect.github.com/aws-powertools/powertools-lambda-typescript/issues/3838">#3838</a>)</li> <li><a href="https://github.com/aws-powertools/powertools-lambda-typescript/commit/e3206fcf7d802395d3b8cd53082c4df1756905ff"><code>e3206fc</code></a> chore(deps): bump squidfunk/mkdocs-material from sha256:23b69789b1dd836c53ea2...</li> <li>Additional commits viewable in <a href="https://github.com/aws-powertools/powertools-lambda-typescript/compare/v2.18.0...v2.19.0">compare view</a></li> </ul> </details> <br /> [![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.18.0&new-version=2.19.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) --- <details> <summary>Dependabot commands and options</summary> <br /> 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) </details> --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Anthony Brown <[email protected]>
1 parent 274f666 commit 989ee66

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

.tool-versions

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
nodejs 20.11.0
1+
nodejs 20.19.0
22
python 3.8.15
33
poetry 1.6.1
44
shellcheck 0.9.0

package-lock.json

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"typescript": "^5.8.3"
3636
},
3737
"dependencies": {
38-
"@aws-lambda-powertools/logger": "^2.18.0",
38+
"@aws-lambda-powertools/logger": "^2.19.0",
3939
"@middy/core": "^6.1.6",
4040
"conventional-changelog-eslint": "^6.0.0"
4141
},

0 commit comments

Comments
 (0)