Skip to content

1.15

Compare
Choose a tag to compare
@github-actions github-actions released this 08 Oct 14:46
· 30 commits to refs/heads/develop since this release
a979415

Summary

In this release we are excited to announce a new feature in the Batch processing utility and bug fixes in Tracing and Logging.

New Feature: ThrowOnFullBatchFailure

This release introduces a new batch processing option: ThrowOnFullBatchFailure. This option controls whether a BatchProcessingException should be raised on full batch failure.

⭐ Special thanks to @lachriz-aws for developing this feature.

Batch processing 1.2.0

The ThrowOnFullBatchFailure option can be set via:

  • A new ThrowOnFullBatchFailure field on the BatchProcessor attribute (applied in non-utility mode)
  • A new environment variable POWERTOOLS_BATCH_THROW_ON_FULL_BATCH_FAILURE (applied in non-utility mode)
  • Directly on the AWS.Lambda.Powertools.BatchProcessing.ProcessingOptions in utility mode

ThrowOnFullBatchFailure attribute usage
ThrowOnFullBatchFailure ProcessingOptions usage

Behavior

When processing of an entire batch fails:

  • If ThrowOnFullBatchFailure is set to false, the Batch Processor will not throw an exception after batch processing has completed. Instead, it will return the IDs of the failed items (all batch items in this case) and exit gracefully.
  • If a Lambda function is configured with ErrorHandlingPolicy = StopOnFirstBatchItemFailure and the first batch item fails processing, the entire batch is marked as failed (as per the documentation). In this case, if ThrowOnFullBatchFailure is set to false, the behavior described above will apply.

Note: The new ThrowOnFullBatchFailure option is compatible with the existing error handling policies.

Bug Fixes

Tracing Update

  • Updated to version 1.5.2
  • Fixed issue #659: Lambda timeout when calling async methods from a Tracing decorated method in version 1.5.1
  • Thanks to @JonathanVerberne for reporting this issue

Logging Update

  • Updated to version 1.6.1
  • Fixed issue #656: Serialization exceptions when running .NET 8 non-AOT Lambda functions
  • Thanks to @nCubed for reporting this issue

Changes

🌟New features and non-breaking changes

  • feat: New batch processing option: 'ThrowOnFullBatchFailure' (#646) by @lachriz-aws

📜 Documentation updates

  • feat: New batch processing option: 'ThrowOnFullBatchFailure' (#646) by @lachriz-aws

🔧 Bug Fixes

  • chore: Fix Lambda timeout with Tracing 1.5.1 using async methods (#660) by @hjgraca
  • chore: Remove TypeInfoResolver from non AOT mode. (#657) by @hjgraca
  • chore: update logging nuget package version v 1.6.0 (#652) by @hjgraca

This release was made possible by the following contributors:

@hjgraca and @lachriz-aws