Slide 1

Slide 1 text

API Gateway in Microservice Architecture Ridwan Olalere

Slide 2

Slide 2 text

Microservices Architecture

Slide 3

Slide 3 text

Microservices before API Gateway

Slide 4

Slide 4 text

Constraints ● Spaghetti Integration ● Unnecessary payload to clients ● Client changes every time there is a change in any of the microservices ● Tight coupling ● Impossible to move fast ● Latency problems for mobile clients ● Multiple round trips for mobile clients ● Excess network calls Complex setup

Slide 5

Slide 5 text

Then came BFF as a solution

Slide 6

Slide 6 text

What is an API Gateway ? An application layer/edge service that can manage client interaction with a cluster of APIs. A BFF described in the previous slide is a kind of API gateway Features of API Gateways. 1. Routing 2. Authentication 3. Rate Limiting 4. Caching 5. Dependency resolution 6. Response filtering 7. Request/Response Intercept 8. Granular control and logging 9. Response composition 10. Load balancing 11. Service discovery

Slide 7

Slide 7 text

API Gateways

Slide 8

Slide 8 text

New Entrant → Bruff Express An API gateway built on Nodejs as an express middleware. https://github.com/darilldrems/bruff-express Features ● Routing ● Request Interceptor ● Response Matching ● Request dependency resolution ● Response filtering ● Response caching ● Extensible NB: since bruff is an express middleware, you can have other middleware mapped before bruff for other functions like authentication.

Slide 9

Slide 9 text

A simple Bruff config

Slide 10

Slide 10 text

Experience using bruff ● Its simple to use ● It makes client apps really fast ● It allowed us build core microservices for everyone ● Fast delivery of composite APIs

Slide 11

Slide 11 text

Limitations with bruff ● No circuit breaker ● No Authentication layer ● Does not support logging yet

Slide 12

Slide 12 text

No content