Nerd For Tech
Published in

Nerd For Tech

AppSync GraphQL Gateway as a Router in Gateway design Pattern and Strangler Pattern to migrate from Monolith to Microservices

Two famous Microservices design patterns are “API Gateway design pattern” and “Strangler pattern”. In this article, I am proposing a design that will merge both patterns together using AWS serverless approach.

The Strangler Pattern

The Strangler Pattern is used to migrate from a legacy system (ex: Monolithic) to a modern system (ex: Microservices). It is defined in Microsoft Design patterns at https://docs.microsoft.com/en-us/azure/architecture/patterns/strangler.

As shown in the figure above, there is a “Strangler Facade” that will route the migrated calls to the modern system and keep strangling the old one, until, eventually, remove the facade and only call the Modern System.

The API Gateway Pattern

As defined at https://microservices.io/patterns/apigateway.html, the API Gateway is used to have a single gateway to the system

AppSync as an API Gateway and Strangler Facade

In this article, the following design uses AWS AppSync as an API Gateway and Strangler Facade as explained in AWS documents at https://aws.amazon.com/blogs/mobile/appsync-microservices/.

Here is the final design:

Thanks

Rany Elhousieny

https://www.linkedin.com/in/ranyelhousieny/

https://rany.elhousieny.com/

https://resume.rany.elhousieny.com

https://ranyel.medium.com/

https://ranyelhousieny.tk/

https://rany.tk

References:

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Rany ElHousieny

Rany ElHousieny

https://www.linkedin.com/in/ranyelhousieny Commercial software development manager offering 25+ years of technical experience. Certified Solutions Architect