Your domain is rich and interconnected, and your API should be too. Upgrade your web API to GraphQL, leveraging its flexible queries to empower your users, and its declarative structure to simplify your code. Absinthe is the GraphQL toolkit for Elixir, a functional programming language designed to enable massive concurrency atop robust application architectures. Written by the creators of Absinthe, this book will help you take full advantage of these two groundbreaking technologies. Build your own flexible, high-performance APIs using step-by-step guidance and expert advice you won't find anywhere else.
GraphQL is a new way of structuring and building web services, and the result is transformational. Find out how to offer a more tailored, cohesive experience to your users, easily aggregate data from different data sources, and improve your back end's maintainability with Absinthe's declarative approach to defining how your API works.
Build a GraphQL-based API from scratch using Absinthe, starting from core principles. Learn the type system and how to expand your schema to suit your application's needs. Discover a growing ecosystem of tools and utilities to understand, debug, and document your API. Take it to production, but do it safely with solid best practices in mind. Find out how complexity analysis and persisted queries can let you support your users flexibly, but responsibly too. Along the way, discover how Elixir makes all the difference for a high performance, fault-tolerant API. Use asynchronous and batching execution, or write your own custom add-ons to extend Absinthe. Go live with subscriptions, delivering data over websockets on top of Elixir (and Erlang/OTP's) famous solid performance and real-time capabilities.
Transform your applications with the powerful combination of Elixir and GraphQL, using Absinthe.
What You Need:
To follow along with the book, you should have Erlang/OTP 19+ and Elixir 1.4+ installed. The book will guide you through setting up a new Phoenix application using Absinthe.
It's a great book while it still comes mainly (only?) about syntax & purely technical implementation. Whether it's a problem it's up to you, I couldn't help a feeling of some disappointment.
OK, so what should you know before making a decision about reaching (or not) for this book? 1. it doesn't spend too much time (literally almost zero) on what GraphQL is, what are its origins, how was it initially used, etc. 2. it doesn't care much about architectural constraints of state persistence behind GraphQL - yes, integration with Ecto is covered, but performance considerations are very limited 3. examples are truly good enough to present the syntax & get you started with proper transition of basic concepts into code ... but are far to trivial to match any reasonable R-L situation. In other words - no-one sane would use GraphQL in such a simple scenario - it just doesn't make sense :D And the real challenges start in more complex scenarios with more structured, deeply nested, more or less normalized data
So, is this book worth it? (the money, time & effort) Yes, I think so. Absinthe is a very interesting project & a truly mature one. GraphQL is an interesting concept, there are limited resources on both these technologies, especially keeping in mind that Elixir is still a niche. It's very clear that the author has put a lot of effort into the book & even if it's not the kind of resource & prefer most, I think it's a decent addition to my library.
Great book for a great library. I read about half the book a few years ago but never did much with GraphQL. Recently I was put on a GraphQL project and decided to start a fresh re-read of the book a few weeks ago. I enjoyed the style of the book and how consistently it has stood up over the years. Still very relevant and useful. Highly recommended for people interested in Absinthe.
This was both a practical and a conceptual overview of graphql and absinthe's implementation of it. I am definitely in a position to kick off an implementation of my own apps backed by graphql. I'm not a javascript developer so some of the later chapters around react, apollo and relay could have been expounded further but others may be fine if they're more experienced with these tools.