Solopreneur's Secret Weapon|Developing Microservices Web App with Cursor|From Modular 2 MicroService

preview_player
Показать описание
We dive into the Layers of Microservices Architecture
Layer | Responsibility
API (endpoints) | Handle HTTP, routing
Schemas | Data validation
Services | Business logic
Models | Data structure

Review 30 to 35 Python libraries (equivalent libraries in other languages will be present)
1. API Layer (Router/Controller)
FastAPI → fastapi (for defining routes and handling requests)
Pydantic → pydantic (for request/response validation)
2. Service Layer (Business Logic)
No specific package needed → This layer contains business rules and logic.
3. Data Access Layer (Repository)
SQLAlchemy → sqlalchemy (ORM for database interaction)
Alembic → alembic (for database migrations)
4. Database Layer
PostgreSQL Driver → asyncpg (for PostgreSQL)
MySQL Driver → aiomysql (for MySQL)
SQLite → sqlite3 (built-in)
5. Authentication & Security
JWT → python-jose, pyjwt (for token-based authentication)
Password Hashing → passlib (for bcrypt password hashing)
6. Configuration Management
Dotenv → python-dotenv (for .env configuration loading)
7. Dependency Injection (DI)
FastAPI Depends → fastapi.Depends (for injecting dependencies)
8. Inter-Service Communication
HTTP Requests → httpx (for async HTTP calls)
Message Queue → pika (for RabbitMQ), celery (for task queues)
gRPC → grpcio (for gRPC communication)


The code for supporting notebook is present in the below git repo

You can reach for discovery call at

chapter:
0:00 Intro
0:18 Recap of Scalable App & Challenges
1:30 Components of Monolithic Server
2:10 Layers of Microservices
2:50 Folder structure of Microservices
4:12 Reviewing a Modular Code with Microservices
8:40 Dive in Start Learning about Microservices
10:20 Inter Service Communication
11:55 Core Components of Micro Services
14:00 Python Packages That Support Microservices Code
18:10 Error Handling with Many Classes & Types
19:20 Testing, Deployment and Service Discovery
20:30 Start Small with 2 Services and Practice
21:30 Feeling How Software is Working Intuitivey
22:00 Recap & Outro

PS: Got a question or have a feedback on my content. Get in touch
By leaving a Comment in the video

Want to Consult? Feel free to book a short call with me.

Buy me a Coffee

Рекомендации по теме