![Page 1: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/1.jpg)
www.kontena.io pharos.sh
Why do microservices need an API gateway?
![Page 2: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/2.jpg)
www.kontena.io pharos.sh
Me, myself and I
Jussi NummelinNameCurrent Work
@jnummelin / jnummelinTwitter / Github
Developer Advocate @ Kontena, Inc.
Previous Tecnotree, Digia, Tieto, Nokia, …
Bio All-around handyman on technical topics. Passionate developer and solution architectWorking with containers & microservicesfor ~4 yearsAvid fly-fisher
![Page 3: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/3.jpg)
www.kontena.io pharos.sh
I’ll be rambling about
MicroservicesAPIs
API GatewayPractical example, a.k.a live demo
![Page 4: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/4.jpg)
www.kontena.io pharos.sh
![Page 5: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/5.jpg)
www.kontena.io pharos.sh
Microservices – for context
Independently deployableIsolation
Loose coupling
![Page 6: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/6.jpg)
www.kontena.io pharos.sh
![Page 7: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/7.jpg)
www.kontena.io pharos.sh
Microservices – gains
Faster development cyclesQuality (long term)
Loose coupling
![Page 8: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/8.jpg)
www.kontena.io pharos.sh
Theroadtohellispavedwithgoodintentions
- SaintBernardofClairvaux,ca1150
![Page 9: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/9.jpg)
www.kontena.io pharos.sh
![Page 10: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/10.jpg)
www.kontena.io pharos.sh
Microservices – pains
ComplexityTraceability
Connectivity
![Page 11: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/11.jpg)
www.kontena.io pharos.sh
Client needs to
Adapt to internal changesSupport multiple protocols
Handle variations with each service
![Page 12: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/12.jpg)
www.kontena.io pharos.sh
Enter API Gateway
![Page 13: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/13.jpg)
www.kontena.io pharos.shwww.kontena.io pharos.sh
Façade pattern
The Facade design pattern is often used when a system is very complex or difficult to understand because the system has a large number of interdependent classes or its source code is unavailable. This pattern hides the complexities of the larger system and provides a simpler interface to the client.
- Wikipedia / Gang of Four
![Page 14: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/14.jpg)
www.kontena.io pharos.sh
API Gateway
Intelligent service proxyMiddleware
API Optimization
![Page 15: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/15.jpg)
www.kontena.io pharos.sh
![Page 16: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/16.jpg)
www.kontena.io pharos.sh
API GW as entrypoint
Single entrypointRouting
Protocol translation?
![Page 17: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/17.jpg)
www.kontena.io pharos.sh
API GW as Auth enforcer
Most services need auth
Auth enforcement in each serviceVs.
One-time auth enforcement
![Page 18: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/18.jpg)
www.kontena.io pharos.sh
API GW as Middleware
Rate limitingCaching
AnalyticsRetry policies
![Page 19: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/19.jpg)
www.kontena.io pharos.sh
API GW as Traceabilityenabler
Request/response correlationTracing injection
![Page 20: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/20.jpg)
www.kontena.io pharos.sh
API GW vs. ESB
API GW is NOT an ESBAPI are consumption oriented
ESB is orchestration/reuse focused
![Page 21: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/21.jpg)
www.kontena.io pharos.sh
API GW vs. Service Mesh
Service Mesh is a network functionAPI GW exposes the services
There is a bit of overlap
![Page 22: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/22.jpg)
www.kontena.io pharos.sh
DevOps?
![Page 23: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/23.jpg)
www.kontena.io pharos.sh
API GW & DevOps
Another tool for DevOps Enabler
Continuous Delivery
![Page 24: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/24.jpg)
www.kontena.io pharos.sh
Apps & API GW
Dynamic configApps driven config
![Page 25: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/25.jpg)
www.kontena.io pharos.sh
Options
![Page 26: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/26.jpg)
www.kontena.io pharos.sh
API Gateways
KongTyk
ApiGeeAWS, GCP, Azure,…
![Page 27: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/27.jpg)
www.kontena.io pharos.sh
![Page 28: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/28.jpg)
www.kontena.io pharos.sh
Loadbalancer Kong
ImagesAPI
ProductsAPI
https://github.com/jnummelin/api-gw-example
![Page 29: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/29.jpg)
www.kontena.io pharos.sh
API Gateway
Intelligent service proxyMiddleware
Hide the complexityEnabler for DevOps
![Page 30: Why do microservices need an API gateway?... pharos.sh Façade pattern The Facade design pattern is often used when a system is very complex or difficult to understand because the](https://reader034.vdocument.in/reader034/viewer/2022052611/5f0560c87e708231d412a9e5/html5/thumbnails/30.jpg)
www.kontena.io pharos.sh
" @kontenainc
# slack.kontena.io
$ github.com/kontena/kontena
meetup.com/pro/kontena
% www.kontena.io
Thank You!