aws-patterns

Solid

Lambda best practices, S3 event patterns, SQS/SNS fanout, and DynamoDB access patterns for serverless AWS architectures.

DevOps & Infrastructure 501 stars 42 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 91/100

Stars 20%
90
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# AWS Patterns Serverless and managed service patterns for AWS production workloads. ## Lambda Best Practices ```typescript // Cold start optimization: keep handler thin, initialize outside handler import { DynamoDBClient } from '@aws-sdk/client-dynamodb' import { DynamoDBDocumentClient, GetCommand } from '@aws-sdk/lib-dynamodb' // Initialized ONCE per container (reused across invocations) const client = DynamoDBDocumentClient.from(new DynamoDBClient({})) export const handler = async (event: APIGatewayProxyEvent) => { try { const userId = event.pathParameters?.id if (!userId) { return { statusCode: 400, body: JSON.stringify({ error: 'Missing user ID' }) } } const result = await client.send(new GetCommand({ TableName: process.env.USERS_TABLE!, Key: { pk: `USER#${userId}`, sk: `PROFILE` } })) if (!result.Item) { return { statusCode: 404, body: JSON.stringify({ error: 'User not found' }) } } return { statusCode: 200, headers: { 'Content-Type': 'application/json' }, body: JSON.stringify(result.Item) } } catch (err) { console.error('Handler error:', err) return { statusCode: 500, body: JSON.stringify({ error: 'Internal server error' }) } } } ``` ## S3 Event Processing ```typescript // S3 → Lambda: process uploaded files import { S3Client, GetObjectCommand } from '@aws-sdk/client-s3' const s3 = new S3Client({}) export const handler = async (event: S3Event) => { for (const recor...

Details

Author
vibeeval
Repository
vibeeval/vibecosystem
Created
2 months ago
Last Updated
yesterday
Language
C#
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category