Socket
Socket
Sign inDemoInstall

@aws-sdk/util-retry

Package Overview
Dependencies
2
Maintainers
5
Versions
32
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @aws-sdk/util-retry

Shared retry utilities to be used in middleware packages.


Version published
Maintainers
5
Created

Package description

What is @aws-sdk/util-retry?

The @aws-sdk/util-retry package is part of the AWS SDK for JavaScript v3. It provides utilities to add retry functionality to the AWS SDK operations. This package is designed to help manage retries in a more efficient and customizable way, allowing developers to handle transient errors by repeating requests without having to implement their own retry logic.

What are @aws-sdk/util-retry's main functionalities?

Configuring retry strategies

This feature allows developers to configure retry strategies, specifying how many times an operation should be retried before giving up. The `StandardRetryStrategy` is a built-in strategy that can be used to automatically handle retries according to the SDK's standard logic.

const { StandardRetryStrategy } = require('@aws-sdk/util-retry');
const retryStrategy = new StandardRetryStrategy(maxAttempts);

Custom retry strategy

Developers can extend the `RetryStrategy` class to implement custom retry logic. This allows for fine-grained control over when and how retries should be performed, based on the specific needs of the application.

const { RetryStrategy } = require('@aws-sdk/util-retry');
class MyRetryStrategy extends RetryStrategy {
  constructor(maxAttempts) {
    super();
    this.maxAttempts = maxAttempts;
  }
  shouldRetry(error) {
    // Custom logic to determine if a retry should be attempted
  }
  delayBeforeNextRetry(retryCount) {
    // Custom logic to determine the delay before the next retry
  }
}

Other packages similar to @aws-sdk/util-retry

Changelog

Source

3.229.0 (2022-12-12)

Bug Fixes

  • cloudfront-signer: accept passphrase when signing (#4232) (fcfb59f)

Features

  • client-customer-profiles: This release allows custom strings in PartyType and Gender through 2 new attributes in the CreateProfile and UpdateProfile APIs: PartyTypeString and GenderString. (a57743b)
  • client-ec2: This release updates DescribeFpgaImages to show supported instance types of AFIs in its response. (e6f3672)
  • client-kinesis-video: This release adds support for public preview of Kinesis Video Stream at Edge enabling customers to provide configuration for the Kinesis Video Stream EdgeAgent running on an on-premise IoT device. Customers can now locally record from cameras and stream videos to the cloud on configured schedule. (9bd5310)
  • client-migration-hub-refactor-spaces: This release adds support for Lambda alias service endpoints. Lambda alias ARNs can now be passed into CreateService. (7670f3c)
  • client-rds: Update the RDS API model to support copying option groups during the CopyDBSnapshot operation (2e7020c)
  • client-rekognition: Adds support for "aliases" and "categories", inclusion and exclusion filters for labels and label categories, and aggregating labels by video segment timestamps for Stored Video Label Detection APIs. (0e6020a)
  • client-sagemaker-metrics: This release introduces support SageMaker Metrics APIs. (214fbb7)
  • clients: update client endpoints as of 2022-12-12 (c29fa34)

Readme

Source

@aws-sdk/util-retry

NPM version NPM downloads

An internal package

This package provides shared utilities for retries.

Usage

You probably shouldn't, at least directly.

Keywords

FAQs

Last updated on 12 Dec 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc