Apollo GraphQL Blog
dev-blog.apollodata.com · Company blog · on HN since 2016
Apollo's company blog covers its GraphQL client and server tools, with posts on queries, state management and realtime data.
What HN saysHN links it for GraphQL features like subscriptions, request waterfall optimization and upcoming specs, and for Apollo job listings. One commenter criticizes inefficient queries.
51HN people shared it
19linked it in comments
53stories submitted
1.1Kstory points
8 years agolast shared
2016people per year2026
Most-shared posts
- 1Apollo Client 2.03 people · 164 points · first shared 2017 · 34 comments on HN
- 2Introducing Launchpad: The GraphQL server demo platform3 people · 8 points · first shared 2017 · discussion on HN
- 3GraphQL vs. REST3 people · 5 points · first shared 2017 · discussion on HN
- 4Persisted graphql queries with apollo client 119fd7e6bba53 people · first shared 2017
- 5The future of state management dd410864cae23 people · first shared 2018
- 6The next step for realtime data in GraphQL2 people · 15 points · first shared 2017 · discussion on HN
- 7Exploring Relay Modern: About the Latest RC of Facebook’s JavaScript GraphQL Client2 people · 5 points · first shared 2017 · discussion on HN
- 85 benefits of static GraphQL queries2 people · 5 points · first shared 2016 · discussion on HN
- 9GraphQL Chrome DevTools2 people · 5 points · first shared 2016 · discussion on HN
- 10(Apollo-iOS) Graphql client for swift2 people · 2 points · first shared 2016 · discussion on HN
- 11Securing Your GraphQL API from Malicious Queries2 people · 1 points · first shared 2018 · discussion on HN
- 12Homepage2 people · first shared 2017
- 13New features in graphql batch defer stream live and subscribe 7585d0c28b072 people · first shared 2017
- 14Apollo Client 1.0: A flexible, community-focused JavaScript GraphQL client1 people · 354 points · first shared 2017 · 78 comments on HN
- 15The GraphQL stack: How everything fits together1 people · 210 points · first shared 2017 · 113 comments on HN
What HN people wrote when they linked it
theshawalker · 2017-06-02
Meteor Development Group | Open Source Engineers, Back-end Engineers, Front-end Engineers | San Francisco, CA | Full-time, Onsite and Remote
Back-end Engineers: Build the foundations and APIs of our tools for GraphQL and JavaScript developers. You'll have the opportunity to learn and use the most cutting edge technologies as you help shape and deliver the components that make up our commercial cloud services, Optics and Galaxy. You will work with a team of talented engineers to build performant and scalable services in modern languages like Kotlin and Go.
Front-end Engineers: Design and owns new features for our commercial products, Optics and Galaxy, and our open source projects, Apollo and Meteor. You will be helping to develop the best practices of front-end engineering with a team that has a history of pioneering JavaScript tech.
Open Source Engineers: If you like doing the things above AND attending & speaking at conferences, writing blog posts and teaching people about the latest developer tools, you might be interested in joining our open source team.
If you're wondering what GraphQL and Apollo are all about: https://dev-blog.apollodata.com/
Our job site: https://www.meteor.io/jobs/
skndr · 2018-06-13
> - However the worst thing so far to me has been i have watched as UI developers go from writing simple rest queries, and doing a bit of work on the front-end to writing extremely inefficient and convoluted queries. Even worse is when a third party is doing it and i have no say over what they do with it.
To your last point, there are a few ways you can provide feedback on or limit the cost of your queries. I'd recommend checking out Github's article on resource limitation [0] and the section on query cost analysis in an article by the Apollo team [1].
[0] https://developer.github.com/v4/guides/resource-limitations/
[1] https://dev-blog.apollodata.com/securing-your-graphql-api-from-malicio…
hn_throwaway_99 · 2017-07-28
Here is what's on the horizon: https://dev-blog.apollodata.com/new-features-in-graphql-batch-defer-st…
Subscriptions already exist: https://dev-blog.apollodata.com/graphql-subscriptions-in-apollo-client…
andrewingram · 2017-07-24
Mostly i'm referring to the methodology I followed here: https://dev-blog.apollodata.com/optimizing-your-graphql-request-waterf…
I haven't looked into optimising other types of architecture (eg GraphQL server talking directly to the database), but there seem to be plenty of solutions that people are happy with.
arbesfeld · 2017-04-21
If you're interested in front-end development, there are a few companies which focus on that:
- Apollo/Meteor: https://dev-blog.apollodata.com/
- Auth0: https://auth0.com/blog/tech/
- Chroma: https://blog.hichroma.com/
- LogRocket (my company): https://blog.logrocket.com/
djmashko2 · 2017-04-18
Hi, I'm from the Apollo Client team.
We're going to write some more content in the coming days or weeks about the differences, but here are some of my main thoughts based on following along during Relay Modern development:
1. Relay uses a build process to generate code for queries. That allows some better performance optimizations and static typing out of the box. However, it prevents you from doing anything which requires arbitrary knowledge of the queries at runtime. It also means that if, for some reason, you can't use the build tooling, you can't use Relay. That's actually the original reason we started working on Apollo instead of using Relay ourselves. Apollo works with regular GraphQL ASTs at runtime, so you can use and write tools to work with those queries in any way you like. While it's not something all apps need, we've found some situations where this is desirable, especially for developers building companion libraries.
2. Relay doesn't have as many facilities for updating the store and working with mutation results. Apollo Client has a unique way to use GraphQL fragments and queries to read and write to/from the store, the most recent of which is described here: https://dev-blog.apollodata.com/apollo-clients-new-imperative-store-ap…
3. The Apollo Store is a plain JavaScript object, which means it can be easily serialized, persisted, hydrated, etc. So for example doing server-side rendering where you also hydrate the state is super simple in…
jlu · 2018-03-14
For a better introduction on how Apollo v2 (the graphql client) could replace redux, read this: https://dev-blog.apollodata.com/the-future-of-state-management-dd41086…
I’ve personally tried it (with special attention on its capability to manage local state) and it did work out pretty well, with a lot of redux boilerplate code eliminated and a more effecient workflow, better yet, now you just need to learn one graphql syntax to rule them all.
asp2insp · 2018-03-13
I think the GP is referring to Apollo Client 2's ability to abstract over the underlying data source. Their intro blog post for the 2.0 announcement gives a good overview: https://dev-blog.apollodata.com/apollo-client-2-0-5c8d0affcec7
nothrows · 2018-03-13
TL;DR click bait. The author is replacing Redux with Apollo - a client side graphql library that HAS BUILT IN STATE MANAGEMENT, which he fails to differentiate or mention... Apollo is similar to the firebase event / subscription model.
https://dev-blog.apollodata.com/tutorial-graphql-subscriptions-client-…
xbryanx · 2018-03-01
I think it'll also be interesting to see how Apollo continues to evolve in this space as more people adopt GraphQL in their React apps. Apollo is getting more and more state management features that can handle lots of what Redux is doing:
https://dev-blog.apollodata.com/the-future-of-state-management-dd41086…
joshribakoff · 2018-03-01
https://dev-blog.apollodata.com/the-future-of-state-management-dd41086…
What about apollo-link-state? Not a replacement either per se, but seems like its one step closer to isomorphic (client & server side) state.
On one hand it normalizes your data & avoids thousands of lines of boilerplate, on the other hand you lose [some] control of the underlying data structures which is where you'd still need something like redux.
sorenbs · 2017-12-01
A few articles on the same topic:
https://blog.graph.cool/thinking-in-terms-of-graphs-a9087423645
https://dev-blog.apollodata.com/the-concepts-of-graphql-bc68bd819be3
And a more full featured tutorial:
https://www.howtographql.com/
Full disclosure - I'm the co-founder of Graphcool.
nijynot · 2017-11-09
Check out this article [1] (or video) on Dan Schafer's talk, on how they use Dataloader and GraphQL internally at Facebook. Covers most of it.
To summarize, they create a class for each GraphQLType which has their own "gen" function such that it is the only way to generate data. This way you get a single source of truth.
There's also a video of Lee Byron going through Dataloader's source code which was pretty fun to watch.
[1]: https://dev-blog.apollodata.com/graphql-at-facebook-by-dan-schafer-38d…
JackuB · 2017-11-09
It got more approachable for me when I started to think about it as a specific "backend for frontend" pattern. I don't see it as a _real_ competitor to REST, even though it's trying to market itself this way.
I think recent "@rest" addition from Apollo ( https://dev-blog.apollodata.com/apollo-client-2-0-5c8d0affcec7 ) shows they can easily live together - backend uses REST and frontend can rely on GraphQL.
aocvr · 2017-10-02
> You'll also lose a lot of control over your queries which was a big reason for me to move from Django/Rails/etc. style tools to trying out GraphQL.
For restricting queries, an option is using persisted queries (e.g. https://dev-blog.apollodata.com/persisted-graphql-queries-with-apollo-…
The idea is nice, having full control in development while locking down allowed queries in production.
You'd still have to deal with the problems you mentioned in development, some of which are indeed a little ugly (at least currently).
dmalik · 2017-09-20
Yes, now that you mention it, I do remember hearing about Falcor. For anyone that's interested I found this comparison:
https://dev-blog.apollodata.com/graphql-vs-falcor-4f1e9cbf7504
marktani · 2017-04-19
Even though subscriptions are very much in progress from a specification point of view, the community came up with different approaches that are already employed in practice.
Here are some additional resources:
- RFC for GraphQL subscriptions: https://github.com/facebook/graphql/pull/267
- How to use Subscriptions in GraphiQL: https://dev-blog.apollodata.com/how-to-use-subscriptions-in-graphiql-1…
- Using GraphQL Subscriptions with Apollo: https://www.youtube.com/watch?v=wo9XFmW0W2c
If you want to use GraphQL subscriptions right now, I encourage you to try out our demo over at https://demo.graph.cool/worldchat/. I work at Graphcool :)
ianstormtaylor · 2018-06-14
Quiver looks interesting, congrats on launching! It seems like it will be very useful for internal GraphQL APIs.
It does bring up something that I think the GraphQL community hasn't really addressed well yet though... Part of the way Quiver works is that it only allows pre-defined queries which can then be compiled ahead of time.
> Only allow certain queries from a document store.
This is becoming a common response for how to make GraphQL performant and "secure". [1]
But this solution only works for internal APIs. If you're trying to expose a public GraphQL API it isn't viable.
Not only that, but to sync these "persisted" queries from the client to the server, lots of the persisted query tools require you to hard-code GraphQL queries as `.graphql` files in your repository... effectively re-inventing hard-coded REST responses. Except with an extra build process between the client and the server for each new deploy. You no longer really have each component requesting exactly what it needs.
The more research I do into GraphQL, the more it seems like the promise of "query anything" that libraries are selling is often discarded when you get to actual implementation. And you end up with a situation that is much more similar to REST/HTTP than originally intended.
[1]: https://dev-blog.apollodata.com/persisted-graphql-queries-with-apollo-…
scottmf · 2017-08-05
I'm genuinely surprised by the number of people on HN who seem to know very little about what has been safe to call the successor to REST for quite some time.
Forgive me if this sounds hyperbolic, but unless you have unusual or strict requirements, building a new app in 2017 REST-first is most likely a terrible mistake.
Let me clear up some misconceptions I see in almost every HN comment thread on GraphQL:
1. GraphQL isn't more suited to Graph databases. Your data sources can be a mix of relational DB, NoSQL, key value, a REST API, or anything else.
2. n+1 has always been a solved problem in GraphQL thanks to DataLoader[1], a query batching utility which coalesces calls to your data sources from different parts of your app, specifically to avoid n+1.
3. It's unquestionably production-ready, battle-tested, has a real spec and official reference implementation, and it's probably the safest bet you can make at this moment in an industry as fickle as this.
With GraphQL you simply write your schema, define types and relationships, and you’re then able to request data in almost any shape you wish, with very little extra work. This is invaluable during development.
If you have a list of recent comments with author names, and later decide to show an avatar alongside the name, you don’t need to write any extra code on the server. You add an extra line to your query (or component’s fragment) on the client.
The same goes for any field, any relationship, no matter how complex…