Security News
pnpm 10.0.0 Blocks Lifecycle Scripts by Default
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
serverless-offline-dynamodb-streams
Advanced tools
Emulate AWS λ and DynamoDB streams locally when developing your Serverless project
This Serverless-offline-dynamodb-streams plugin emulates AWS λ and DynamoDBStreams on your local machine. To do so, it listens DynamoDBStreams stream and invokes your handlers.
Features:
First, add serverless-offline-dynamodb-streams
to your project:
npm install serverless-offline-dynamodb-streams
Then inside your project's serverless.yml
file, add following entry to the plugins section before serverless-offline
(and after serverless-webpack
if present): serverless-offline-dynamodb-streams
.
plugins:
- serverless-webpack
- serverless-offline-dynamodb-streams
- serverless-offline
Ths configuration of function of the plugin follows the serverless documentation.
functions:
myKinesisHandler:
handler: handler.compute
events:
- stream:
enabled: true
type: dynamodb
arn: arn:aws:dynamodb:eu-west-1:XXXXXX:table/myStream/stream/2018-07-02T19:48:31.121
batchSize: 10
startingPosition: TRIM_HORIZON
The configuration of aws.DynamoDBStreams
's client of the plugin is done by defining a custom: serverless-offline-dynamodb-streams
object in your serverless.yml
with your specific configuration.
You could use mhart's Dynalite with the following configuration:
custom:
serverless-offline-dynamodb-streams:
apiVersion: '2013-12-02'
endpoint: http://0.0.0.0:8000
region: eu-west-1
accessKeyId: root
secretAccessKey: root
skipCacheInvalidation: false
readInterval: 500
arn
could be deduce fromtableName
if your add the keytableName
in your function's configuration. Useful if your use dynalite and regularly recreate a new DynamoDBStreams.
functions:
myKinesisHandler:
handler: handler.compute
events:
- stream:
enabled: true
type: dynamodb
tableName: myTable
FAQs
Emulate AWS λ and DynamoDB streams locally when developing your Serverless project
We found that serverless-offline-dynamodb-streams demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 24 open source maintainers collaborating on the project.
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.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
Product
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.
Research
Security News
Socket researchers have discovered multiple malicious npm packages targeting Solana private keys, abusing Gmail to exfiltrate the data and drain Solana wallets.