Socket
Socket
Sign inDemoInstall

serverless-offline-sqs-dlq

Package Overview
Dependencies
604
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    serverless-offline-sqs-dlq

Enable Dead-Letter-Queue with AWS λ and SQS locally when developing your Serverless project


Version published
Weekly downloads
97
decreased by-49.48%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

serverless-offline-sqs-dlq

This Serverless-offline plugin brings Dead-Letter Queues to AWS λ and SQS queue on your local machine. It extends serverless-offline-sqs and thus depends on it.

Warning: Serverless doesn't support yet SQS for DLQ. After the deployment on AWS, the DLQ needs to be set on AWS (either manually or by a script).

Installation

First, ensure to have serverless-offline-sqs included in your project:

npm install serverless-offline-sqs serverless-offline-sqs-dlq

Then inside your project's serverless.yml file, add following entries to the plugins section before serverless-offline (and after serverless-webpack if presents).

plugins:
  - serverless-webpack
  - serverless-offline-sqs
  - serverless-offline-sqs-dlq
  - serverless-offline

Configure

Usage:

functions:
  basicLambda:
    handler: index.basicLambda
    events:
      - sqs: arn:aws:sqs:eu-west-1:XXXXXXX:basicLambdaTriggerQueue
  handleErrorLambda:
    handler: index.handleErrorLambda
    events:
      - sqs: arn:aws:sqs:eu-west-1:XXXXXXX:handleErrorLambdaQueue

Specify in the custom section which function handles errors:

custom:
  (...)
  serverless-offline-sqs-dlq:
    basicLambda:
      onError: handleErrorLambda
      maxReceiveCount: 3

Keywords

FAQs

Last updated on 27 Jun 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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc