[go: up one dir, main page]

Skip to content

Spring cloud gateway for ecommerce microservices based on spring-boot 3

License

Notifications You must be signed in to change notification settings

amol9372/ecomm-gateway

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gateway application for Ecommerce Project

Tech Stack

  • Java 17
  • Spring boot 3
  • Spring Cloud Gateway
  • Postgres
  • Spring Webflux

Features

This project includes the follwing features

  • JWT Authentication & Authorization with Token generation
  • Reactive authentication manager
  • Postgres Integration
  • API realtime events using websocket (use ws://localhost:8091/ws/events in postman or any language)

Run application locally

Set the environment variables

you can set below env variables in a file called .env

Variable Name Value Description
AUTH0_ISSUER https://mydomain.us.auth0.com/ URL for the Auth0 issuer used for token validation
AUTH0_USERINFO_URL https://mydomain.us.auth0.com/userinfo URL to retrieve Auth0 user information
POSTGRES_DB sampledb The name of your PostgreSQL database
POSTGRES_PASSWORD password Password for your PostgreSQL database
POSTGRES_URL localhost Hostname & domain of your PostgreSQL database
POSTGRES_USER postgres Username for your PostgreSQL database

Use the docker file to build and run the application

docker build -t ecomm-gateway .

Run the application

docker run -it --env-file ./.env -p 8091:8091 -d ecomm-gateway

APIs

Use this postman collection to create & authenticate users ecommerce-backend-apis