4 ms·
(Dgraph founder here) > The decision to adapt GraphQL instead of supporting Cypher, what would you say were the big trade offs? Cypher was built around SQL, w
by mrjn 7y ago
(Dgraph founder here)
> The decision to adapt GraphQL instead of supporting Cypher, what would you say were the big trade offs?
Cypher was built around SQL, with the idea that people are used to SQL. Therefore, by having something similar, people would find it easier to adapt. Many years later, I'd say it still hasn't gained as much popularity beyond Neo4j as sometimes projected.
We bet upon GraphQL in 2015, because it was easy to understand, worked with JSON and resulted in sub-graphs. While Cypher and Gremlin return lists of things. One can go from subgraph to lists, but not the other way around, because relationships are lost.
Within 3 years of draft spec, GraphQL has taken the developer world by storm. Developers find it easy to wrap their heads around and enjoy working with it. In fact, GraphQL+- (our language) has become one of the USPs of Dgraph.
> Would you say more that you can get Mongo and Redis (+redisgraph) users to switch to Dgraph, or instead more that the main customers for graph databases are still in school right now and deciding what tech skills will underpin their careers?
We have heard from many user who would have used MongoDB or SQL if not for Dgraph. With Mongo, you get scalability, but at the cost of query complexity and transactionality (/correctness). Keys and Docs are nice, but they don't let you use relationships to interact with a wider dataset. With Dgraph, you get scalability, while also gaining a much richer and sophisticated querying ability, transactionality (distributed txns), correctness without losing query performance. My blog post says more about this.
Redis is a cache, so people are not directly comparing it against Dgraph, a persistence-first database. One could use Redis to perhaps store Dgraph results.
- TimFogarty 7y agoHey Manish! Congratulations to you and your team on the round! It's a phenomenal achievement. You mentioned transactions... I work for MongoDB so I just wanted to add that MongoDB does have ACID transactions since version 4.0. Distributed transactions will be included in the upcoming 4.2 release. There's more info on distributed transactions in the 4.2 release here if you're interested: https://docs.mongodb.com/master/core/transactions/ https://docs.mongodb.com/master/core/transactions/ By the way, it's awesome to see you're using Go. I just got into it recently and it's such a nice language to work with.
- mrjn 7y agoGood to hear Mongo would have distributed transactions. Go is awesome. I picked a t-shirt from Mongo's booth at Gophercon, nice stuff!
- TimFogarty 7y agoOh I was just at GopherCon! I was on the Mongo booth.
- panarky 7y ago> Redis is a cache Redis is much more than a cache, you can model graph data structures with Redis primitives, and the redisgraph module compares directly against Dgraph.
- mrjn 7y agoYeah, sorry for missing Redisgraph. The entire graph is stored in memory and only spans one server. I personally am not sure what happens when that server goes down. How many minutes worth of data is lost? What's the replication strategy for another server to take over the traffic? And what about transactions and correctness? Those things matter a lot to Dgraph users who are storing and serving their source of truths. Horizontal scalability, persistence, correctness and avoiding downtime with consistent replication have been cornerstones for the design of Dgraph.
- jacquesm 7y agoIt's a bit disappointing that you would talk down a competitor without knowing much about them, and then, to add insult to injury speculate about all kinds of things without having facts to diss them some more.
- mrjn 7y agoYou're misinterpreting me. I haven't talked down about them. And definitely don't think of them as a competitor. My point was that those questions I mentioned above are important to Dgraph users and I don't think Redis even projects itself as a persistence-first DB. I might be wrong. Either ways, our audience is quite different when it comes to enterprises at least. I know the founders of Redis Labs, met them as well and they're awesome people.
- futureastronaut 7y agoI'm more disappointed that a founder answering questions has somebody jumping down their throat for a perceived slight in a tiny portion of their reply. But that's HN.
- breck 7y agoIf anyone on your team is interested, we are working on a new plain text graph database called TreeBase: https://treenotation.org/treeBase/ https://treenotation.org/treeBase/. Perhaps there are ideas you all could take away that would help make your products better. I've been following Dgraph for a while and your GraphQL+- iteration on GraphQL. Clearly you folks understand the semantics and how to build a database that can handle massive scale. Our focus is on much smaller databases (at the moment, nothing larger than what would be a few million rows), but I think the syntax we have makes the whole thing easier to understand and makes data more accessible to users. Maybe this is completely irrelevant, but if there might be something of value to your users here, feel free to have someone get in touch: yunits@hawaii.edu. (we are trying to get help advancing the state of the art in DB to make cancer and medical research easier)