Skip to content

mikelm2020/sam-eventbridge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contributors Forks Stargazers Issues MIT License LinkedIn


Logo

Serverless project with Amazon EventBridge

A simple microservice application using AWS SAM, that uses Amazon EventBridge as at messaging between microservices.

Table of Contents
  1. About The Project
  2. Contact
  3. Acknowledgments

About The Project

This project has a simple application where you can send food orders to different restaurants based on an API Request. And using EventBridge each restaurant will recieve the right order. You can extend this just by adding more restaurants microservice. Each restaurant is in control of their EventBridge rule, in this way we keep the whole application very decoupled. Also is used a microservice for send food orders to API Destination and control when events can't delivery, through a DLQ Dead Letter Queue for process the message later saving to DynamoDB Table.

Architecture

Basic Arquitecture

API Destination Arquitecture

DLQ Arquitecture

(back to top)

Deploy the project

You will need to deploy each microservice individually - orderManager, pizzaHat and Thailand.

Also the microservice blueDragon for show API Destinations with the site https://webhook.site/

We will be using AWS SAM and make sure you are running the latest version - at the time of writing, this was 1.78.0 (sam --version).

Deploy the project to the cloud:

sam deploy --guided

When asked about functions that may not have authorization defined, answer (y)es. The access to those functions will be open to anyone, so keep the app deployed only for the time you need this demo running.

Next times, when you update the code, you can build and deploy with:

sam deploy

To delete the app:

sam delete

Built With

  • Python
  • AWS
  • Visual Studio Code

AWS Services

  • Amazon EventBridge
  • Amazon API Gateway
  • AWS Lambda
  • AWS SAM
  • AWS SDK Python
  • Amazon SQS
  • Amazon DynamoDB
  • Amazon CloudWatch

(back to top)

Contact

Miguel Angel López Monroy - linkedin Gmail-shield Twitter-shield

(back to top)

Acknowledgments

My favorite resources used:

(back to top)