Hold the door! Powerful API gateways with Ocelot and ASP.Net Core
summary
Builds an API gateway with Ocelot + ASP.Net Core that proxies requests, does response aggregation, header transformation (pulls JWT claims into headers), load balancing, caching, rate limiting and service discovery — all configured in ocelot.json so most scenarios need no custom code. Demo runs three services (auth, gateway, product) on ports 5001–5003, shows logs proving authorization and header propagation, and the gateway is testable via ASP.NET Core TestServer; it works as advertised.
AI-written summary · about
chapters (17)
- 0:00Introduction and speaker intro
- 1:49What are microservices?
- 3:12Role of API gateways
- 4:36Why API gateways are needed
- 7:06Key API gateway features
- 9:37Introducing Ocelot library
- 10:41Ocelot features overview
- 12:46How Ocelot works under the hood
- 14:30Ocelot configuration basics
- 17:00Routing with reroutes
- 20:14Authentication and authorization
- 21:59Header transformation
- 22:50Live demo setup
- 26:32Running the demo
- 29:32Demo code walkthrough
- 32:05Ocelot in production
- 33:20Q&A session
