Use HTTP/2 Server Push to create fast and idiomatic client-driven REST APIs ↦
Around the advent of GraphQL, I found myself asking its proponents if HTTP/2 solves any of the same performance problems. Most of the answers were along the lines of, “it might, but that hasn’t been realized yet.” Well, Vulcain is here to realize it.
Over the years, several formats have been created to fix performance bottlenecks impacting web APIs: over fetching, under fetching, the n+1 problem…
Current solutions for these problems (GraphQL, JSON:API’s embedded resources and sparse fieldsets, …) are smart network hacks for HTTP/1. But these hacks come with (too) many drawbacks when it comes to HTTP cache, logs and even security.
Fortunately, thanks to the new features introduced in HTTP/2, it’s now possible to create true REST APIs fixing these problems with ease and class! Here comes Vulcain!
See also their comparison between Vulcain, GraphQL, and API formats.
Sign in or Join to comment or subscribe
Jerod co-hosts The Changelog, crashes JS Party, and takes out the trash (his old code) once in awhile.
Digging deeper into the docs, it looks like you can even use GraphQL as a query language for Vulcain. They’ve put a lot of thought into this…
Not sure how I feel about the
Preloadheader, but there are many interesting things to chew on here.