Skip to content

New example of SQS with Typescript #451

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Mar 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ serverless install -u https://github.com/serverless/examples/tree/master/folder-
| [Baddadjokesbot](https://github.com/serverless/examples/tree/master/aws-node-twitter-joke-bot) | nodeJS |
| [Nest Serverless](https://github.com/serverless/examples/tree/master/aws-node-typescript-nest) <br/> serverless app | nodeJS |
| [Typescript Example](https://github.com/serverless/examples/tree/master/aws-node-typescript-rest-api-with-dynamodb) | nodeJS |
| [Aws Node Typescript Sqs Standard](https://github.com/serverless/examples/tree/master/aws-node-typescript-sqs-standard) <br/> Serverless example using Standard SQS with TypeScript | nodeJS |
| [Upload To S3 And Postprocess](https://github.com/serverless/examples/tree/master/aws-node-upload-to-s3-and-postprocess) <br/> Upload a files to S3 to trigger a lambda function. | nodeJS |
| [Aws Node Vue Nuxt Ssr](https://github.com/serverless/examples/tree/master/aws-node-vue-nuxt-ssr) <br/> Sample project for using Nuxt.js to create a server-side rendered Vue.js app on AWS Lambda and AWS API Gateway. Can easily integrate with your own API or 3rd party APIs such as headless CMS, e-commerce or serverless architecture. | nodeJS |
| [Aws Nodejs Websockets Authorizers](https://github.com/serverless/examples/tree/master/aws-node-websockets-authorizers) <br/> Simple example that demonstrates how to use authorizer functions with websocket events | nodeJS |
Expand Down
9 changes: 9 additions & 0 deletions aws-node-typescript-sqs-standard/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# package directories
node_modules
jspm_packages

# Serverless directories
.serverless

# Webpack directories
.webpack
27 changes: 27 additions & 0 deletions aws-node-typescript-sqs-standard/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<!--
title: 'AWS SQS Standard Example (NodeJS & Typescript)'
description: 'This example demonstrates how to setup a SQS with Typescript.'
layout: Doc
framework: v1
platform: AWS
language: nodeJS
authorLink: 'https://github.com/jmpfrazao'
authorName: 'Miguel Frazao'
authorAvatar: 'https://avatars3.githubusercontent.com/u/28927258?s=460&v=4'
-->
# Simple SQS Standard Example

This example demonstrates how to setup a SQS Standard and send messages through the message body and attributes.

## Use Cases
- Decouple message producers from message consumers.
- This is one way to architect for scale and reliability.

## Setup
- sls deploy

## Usage
- To print out the logs of the receiver sqs handler on the terminal
`sls logs -f receiver -t`

- send a HTTP POST request to the sender lambda with a JSON payload
2 changes: 2 additions & 0 deletions aws-node-typescript-sqs-standard/handler.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export { default as sender } from './sqs/sender';
export { default as receiver } from './sqs/receiver';
Loading