diff --git a/aws_lambda_powertools/utilities/batch/sqs.py b/aws_lambda_powertools/utilities/batch/sqs.py index 0848e327ea6..7b234c1372e 100644 --- a/aws_lambda_powertools/utilities/batch/sqs.py +++ b/aws_lambda_powertools/utilities/batch/sqs.py @@ -6,6 +6,7 @@ import logging import math import sys +import warnings from concurrent.futures import ThreadPoolExecutor, as_completed from typing import Any, Callable, Dict, List, Optional, Tuple, cast @@ -77,6 +78,14 @@ def __init__( self.suppress_exception = suppress_exception self.max_message_batch = 10 + warnings.warn( + "The sqs_batch_processor decorator and PartialSQSProcessor class are now deprecated, " + "and will be removed in the next major version. " + "Please follow the upgrade guide at " + "https://awslabs.github.io/aws-lambda-powertools-python/latest/utilities/batch/#legacy " + "to use the native batch_processor decorator or BatchProcessor class." + ) + super().__init__() def _get_queue_url(self) -> Optional[str]: diff --git a/docs/overrides/main.html b/docs/overrides/main.html index 0af326afb24..e7908bbfa32 100644 --- a/docs/overrides/main.html +++ b/docs/overrides/main.html @@ -1,5 +1,10 @@ {% extends "base.html" %} +{% block announce %} + 👋 Powertools for Python v2 is coming soon! + We encourage you to add your feedback and follow the progress on the RFC. +{% endblock %} + {% block outdated %} You're not viewing the latest version. diff --git a/docs/utilities/batch.md b/docs/utilities/batch.md index ce2e76e25d4..6241179ed4e 100644 --- a/docs/utilities/batch.md +++ b/docs/utilities/batch.md @@ -5,6 +5,11 @@ description: Utility The batch processing utility handles partial failures when processing batches from Amazon SQS, Amazon Kinesis Data Streams, and Amazon DynamoDB Streams. +???+ warning + The legacy `sqs_batch_processor` decorator and `PartialSQSProcessor` class are deprecated and are going to be removed soon. + + Please check the [migration guide](#migration-guide) for more information. + ## Key Features * Reports batch item failures to reduce number of retries for a record upon errors diff --git a/mkdocs.yml b/mkdocs.yml index 5b08b31a81d..171cf36eb13 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -47,6 +47,7 @@ theme: icon: material/toggle-switch name: Switch to light mode features: + - header.autohide - navigation.sections - navigation.expand - navigation.top