The Serverless Mindset

Share this post

Parallelise Development by Using Mock Resolvers With AppSync

www.theserverlessmindset.com

Parallelise Development by Using Mock Resolvers With AppSync

An API-first approach using GraphQL with AppSync

Marco Troisi
Jul 7, 2022
1
3
Share this post

Parallelise Development by Using Mock Resolvers With AppSync

www.theserverlessmindset.com

Here’s a technique I've successfully used with teams when building functionalities that require both backend and frontend development.

I call it mocks resolvers. The idea is stupidly simple, but it has the potential to unblock and parallelise separate streams of development, thus reducing unnecessary blockers and dependencies.

In a nutshell, the mock resolvers technique requires that the team’s first task be to design any GraphQL statements (queries, mutations, etc) needed to build a feature. Immediately after that, a hardcoded set of responses is attached to each query, so that all GraphQL operations are able to receive and respond with the appropriate payload.

At this point, a contract of sorts is established. The frontend team can proceed to build the interface that’s going to use those GraphQL operations, whereas the backend team can focus on building the business logic that will eventually be invoked by AppSync.

Typical “mock resolvers” workflow on a 5-day sprint/cycle

Keep reading with a 7-day free trial

Subscribe to The Serverless Mindset to keep reading this post and get 7 days of free access to the full post archives.

Already a paid subscriber? Sign in
© 2023 Marco Troisi
Privacy ∙ Terms ∙ Collection notice
Start WritingGet the app
Substack is the home for great writing