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

build(deps): bump aws-lambda-powertools from 2.23.0 to 2.25.0 #113

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Sep 18, 2023

Bumps aws-lambda-powertools from 2.23.0 to 2.25.0.

Release notes

Sourced from aws-lambda-powertools's releases.

v2.25.0

Summary

This release simplifies data transformation with Amazon Kinesis Data Firehose, and handling secret rotation events from Amazon Secrets Manager.

🌟 Huge welcome to our new contributor @​TonySherman. Tony documented how to use Event Handler with micro Lambda functions.

Data Transformation code snippet

Data transformation

Docs

When using Kinesis Firehose, you can use a Lambda function to perform data transformation. For each transformed record, you can choose to either:

  • A) Put them back to the delivery stream (default)
  • B) Drop them so consumers don't receive them (e.g., data validation)
  • C) Indicate a record failed data transformation and should be retried

To make this process easier, you can now use KinesisFirehoseDataTransformationResponse and serialization functions to quickly encode payloads into base64 data for the stream.

Example where you might want to drop unwanted records from the stream.

from json import JSONDecodeError
from typing import Dict
from aws_lambda_powertools.utilities.data_classes import (
KinesisFirehoseDataTransformationRecord,
KinesisFirehoseDataTransformationResponse,
KinesisFirehoseEvent,
event_source,
)
from aws_lambda_powertools.utilities.serialization import base64_from_json
from aws_lambda_powertools.utilities.typing import LambdaContext
@​event_source(data_class=KinesisFirehoseEvent)
def lambda_handler(event: KinesisFirehoseEvent, context: LambdaContext):
result = KinesisFirehoseDataTransformationResponse()
for record in event.records:
    try:
        payload: Dict = record.data_as_json  # decodes and deserialize base64 JSON string
    ## generate data to return
    transformed_data = {"tool_used": "powertools_dataclass", "original_payload": payload}

    processed_record = KinesisFirehoseDataTransformationRecord(
        record_id=record.record_id,


</tr></table>

... (truncated)

Changelog

Sourced from aws-lambda-powertools's changelog.

[v2.25.0] - 2023-09-15

Code Refactoring

  • parameters: BaseProvider._get to also support Dict (#3090)

Documentation

  • event_handler: fix typing in micro function example (#3098)
  • event_handler: add micro function examples (#3056)
  • we-made-this: fix broken Twitch video embeds (#3096)

Features

  • event_source: add Kinesis Firehose Data Transformation data class (#3029)
  • event_sources: add Secrets Manager secret rotation event (#3061)

Maintenance

  • version bump
  • automation: remove previous labels when PR is updated (#3066)
  • deps: bump actions/dependency-review-action from 3.0.8 to 3.1.0 (#3071)
  • deps: bump docker/setup-qemu-action from 2.2.0 to 3.0.0 (#3081)
  • deps: bump docker/setup-buildx-action from 2.10.0 to 3.0.0 (#3083)
  • deps: bump squidfunk/mkdocs-material from dd1770c to c4890ab in /docs (#3078)
  • deps-dev: bump cfn-lint from 0.79.9 to 0.79.10 (#3077)
  • deps-dev: bump hvac from 1.2.0 to 1.2.1 (#3075)
  • deps-dev: bump ruff from 0.0.288 to 0.0.289 (#3080)
  • deps-dev: bump ruff from 0.0.287 to 0.0.288 (#3076)
  • deps-dev: bump aws-cdk from 2.95.0 to 2.95.1 (#3074)
  • deps-dev: bump the boto-typing group with 1 update (#3085)
  • deps-dev: bump aws-cdk from 2.95.1 to 2.96.0 (#3087)
  • deps-dev: bump sentry-sdk from 1.30.0 to 1.31.0 (#3086)
  • deps-dev: bump aws-cdk from 2.94.0 to 2.95.0 (#3070)
  • deps-dev: bump cfn-lint from 0.79.10 to 0.79.11 (#3088)
  • deps-dev: bump aws-cdk from 2.96.0 to 2.96.1 (#3093)
  • typing: move backwards compat types to shared types (#3092)

[v2.24.0] - 2023-09-08

Bug Fixes

  • event_handler: expanding safe URI characters to include +$& (#3026)
  • parser: change ApproximateCreationDateTime field to datetime in DynamoDBStreamChangedRecordModel (#3049)

Code Refactoring

  • batch: type response() method (#3023)

Documentation

... (truncated)

Commits
  • 781fbba chore: version bump
  • 5ea0a7f docs(event_handler): fix typing in micro function example (#3098)
  • fb49570 docs(we-made-this): fix broken Twitch video embeds (#3096)
  • 4e8ca0f docs(event_handler): add micro function examples (#3056)
  • 1d502b6 chore(ci): changelog rebuild (#3094)
  • 41345d0 chore(deps-dev): bump aws-cdk from 2.96.0 to 2.96.1 (#3093)
  • 455836c feat(event_source): add Kinesis Firehose Data Transformation data class (#3029)
  • f673368 chore(typing): move backwards compat types to shared types (#3092)
  • 86619e5 refactor(parameters): BaseProvider._get to also support Dict (#3090)
  • ef4cd09 chore(deps): bump docker/setup-qemu-action from 2.2.0 to 3.0.0 (#3081)
  • Additional commits viewable in compare view

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](https://github.com/aws-powertools/powertools-lambda-python) from 2.23.0 to 2.25.0.
- [Release notes](https://github.com/aws-powertools/powertools-lambda-python/releases)
- [Changelog](https://github.com/aws-powertools/powertools-lambda-python/blob/develop/CHANGELOG.md)
- [Commits](aws-powertools/powertools-lambda-python@v2.23.0...v2.25.0)

---
updated-dependencies:
- dependency-name: aws-lambda-powertools
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label Sep 18, 2023
@dependabot @github
Copy link
Contributor Author

dependabot bot commented on behalf of github Sep 25, 2023

Superseded by #115.

@dependabot dependabot bot closed this Sep 25, 2023
@dependabot dependabot bot deleted the dependabot/pip/aws-lambda-powertools-2.25.0 branch September 25, 2023 12:31
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
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants