4 ms·
Thunk-based Resolvers: How to build a powerful and flexible GraphQL Gateway
- ramesh31 5y agoDear god, just why?
- Soflodeveloper 5y agoThis looks pretty awesome. Going to give it a try.
- gavinray 5y agoThis idea is really, really neat: > " During development, you still write GraphQL queries and mutations, but at runtime, we replace GraphQL with JSON RPC." > "At this point, it should be clear why we introduced the concept of the virtual Graph. If you have a GraphQL API, composed of multiple other APIs, but really only expose a generated REST/JSON RPC, it makes sense to call it "virtual" Graph, as the composed GraphQL Schema only really exists virtually." One question I have -- how did you arrive at the design for the plan/IR representation of a query? Was it a trial-and-error phase or it did it sort of just feel natural and work the first design around?
- jensneuse 5y agoVery early on, I had a pretty good idea of how it should look like. However, the initial design had a few major flaws, so I had to introduce an extra "configuration" walk before doing the actual planning walk. Additionally, I've also added a post processing step, just to remove too much complexity from the planning step itself. In the end, the result is pretty stable and very maintainable, but it's very hard to "onboard" new devs as it's quite a lot of concepts you have to understand before you can become productive...
- gavinray 5y agoThanks for the response, and the article =D This is some really cool work you've done here, lot of neat ideas