Week 1: REST API Principles, gRPC & Service Architecture
Design scalable APIs and microservice architectures: REST principles, gRPC, service mesh patterns, API gateways, and inter-service communication.
- Design REST APIs following OpenAPI spec and best practices
- Implement gRPC services with Protocol Buffers
- Build microservices with proper service discovery and load balancing
- Use API gateways and implement authentication/rate limiting
This first lecture establishes the foundational framework for API Design & Microservices. By the end of this session, you will have the conceptual grounding and practical starting point needed for the rest of the course.
Key Concepts
The lecture introduces the four main pillars of this course: REST API Design: Resources, Methods, Status Codes, gRPC & Protocol Buffers, Service Discovery & Load Balancing, API Gateway: Auth, Rate Limiting, CORS. Each will be explored in depth over the 14-week curriculum, with hands-on projects reinforcing theory at every stage.
This Week's Focus
Focus on mastering: REST API Design: Resources, Methods, Status Codes and gRPC & Protocol Buffers. These are the prerequisites for everything in Week 2. The concepts build on each other — do not skip the practice exercises.
SE201 Project 1: Microservices ML Application
Build a 3-service ML application: a preprocessing service, an inference service, and an API gateway. Implement with FastAPI, containerize with Docker Compose, and add authentication.
- 3 FastAPI microservices with OpenAPI docs
- gRPC inter-service communication
- API gateway with JWT authentication and rate limiting
- Load test: 500 RPS with <100ms p99 latency
These represent the style and difficulty of questions you'll see on the midterm and final. Start thinking about them now.
Explain REST constraints (statelessness, uniform interface, layered system). Why does each matter?
What are the advantages of gRPC over REST for internal microservice communication?
Design the URL structure and HTTP methods for a CRUD API managing ML model versions.