8 ms·
Apache Age: A Graph Extension for PostgreSQL
- fatsdomino001 6y agoI wonder how the inclusion of graph features in Postgres 14 will affect this project.
- jhoechtl 6y agoFrom where do you get that? I was searching the internets for this purported feature and couldn't find it. Link?
- cldellow 6y agoVersion 14 adds some features to recursive CTE expressions to do BFS/DFS searches and cycle detection. As always, depesz has a nice write up of it: https://www.depesz.com/2021/02/04/waiting-for-postgresql-14-search-and-cycle-clauses/ https://www.depesz.com/2021/02/04/waiting-for-postgresql-14-... I _think_ it's just syntactic sugar and doesn't let you do anything you couldn't already do, although perhaps it would leave room in the future for the Postgres team to optimize query execution.
- yamrzou 6y agoThis is based on AgensGraph: http://bitnine.net/downloads-2020/ http://bitnine.net/downloads-2020/ I found this presentation from 2017 about AgensGraph: https://www.slideshare.net/mobile/kisung80/agensgraph-a-multimodel-graph-database-based-on-postgresql https://www.slideshare.net/mobile/kisung80/agensgraph-a-mult...
- gutbasokchok 6y agodownload link changed to https://bitnine.net/agensgraph-downloads/ https://bitnine.net/agensgraph-downloads/
- jacques_chester 6y agoHow would this compare with something like pgRouting (https://pgrouting.org/ https://pgrouting.org/)?
- crad 6y agoI read pgRouting as focusing on Geospacial routing to get from point A to point B. Is there more to it than that? A graph database is about storing data that the relationships between pieces of data, like a social graph as an example. You'd have a people and the relationships between them in the database.
- derefr 6y agoDespite the description on its website, at core, there's nothing particularly geospatial about pgRouting. You don't need PostGIS, or even Postgres's built-in geo types (point, line, etc.), in order to use pgRouting. Rather, pgRouting is a set of general graph- and path-search algorithms, exposed as procedures, that operate upon rowsets (most efficiently, upon indexed tables) of vertices and edges. You can use pgRouting to do SPARQL-like graph queries, or even full-blown network analysis, if you like. In a previous job, I did just that: I loaded up social-network data into vertex and edge tables, and then I used pgRouting's implementation of Floyd-Warshall and Driving Distance to discover high-value potential social connections within a given relationship-weighted distance of a given user. Not as a one-time data-science thing, but as the backend of our service's matching engine, that ran every time a user refreshed their "candidate matches" page. It was pretty instantaneous.
- nathcd 6y agoI remember wondering about exactly this a couple years ago, but I couldn't figure out the answer (I didn't look all that closely into it). Now I want to come up with an excuse to try it out on something. Thanks for mentioning this!
- yowlingcat 6y agoWow, this is super neat. I wish I knew about this a couple years ago, it would've been super useful for a recommendation system I was building in production. I'll have to give this a shot!
- ForHackernews 6y agoFWIW, Postgres already has good support for representing and querying graph structures using the LTree extension https://www.postgresql.org/docs/current/ltree.html https://www.postgresql.org/docs/current/ltree.html
- jimktrains2 6y agoThat's more for trees, which to be fair are a specific kind of graph I guess. Ltree doesn't provide anywhere near the types of tools someone would expect if you told them it supports "graph structures".
- philsnow 6y agothe projects are not related at all but this and https://github.com/FiloSottile/age https://github.com/FiloSottile/age have a name conflict.
- rzzzt 6y agoI like to research meaningless things, so looked at the first commit in each repository: - https://github.com/apache/incubator-age/commit/bef50e5d86d45707806f5733695a229f3e295b1a https://github.com/apache/incubator-age/commit/bef50e5d86d45... (Mar 19, 2019) - https://github.com/FiloSottile/age/commit/06cbe4f91ea984306996d1f7dbde1bb5ffd67fec https://github.com/FiloSottile/age/commit/06cbe4f91ea9843069... (Oct 6, 2019) What does this mean? Absolutely nothing.
- ajankelo 6y agoFantastic that they are using Cypher. Love that language, if one could say that about a Query language.
- hc-taway 6y agoCypher's pretty much the only thing about Neo4j that I found to be both pleasant-to-use and... well, any good, really. Love seeing it borrowed by other graphDBs. I'm far from being a SQL hater, but being able to bounce into Cypher to replace (at least some large subset of) recursive CTEs would be a huge developer-experience improvement for PostgreSQL, for multi-model DBs. Example from the n4j Cypher docs, for the curious: MATCH (user:User { name: 'Adam' })-[r1:FRIEND]-()-[r2:FRIEND]-(friend_of_a_friend) RETURN friend_of_a_friend.name AS fofName Returns names of friends-of-friends (connected with FRIEND-labeled edges) User nodes having the "name" property "Adam". Stuff like "friend_of_a_friend" is set as an alias for the matched nodes, like in SQL. () denotes a node, [] an edge. (It's been a while, so this explanation may be subtly wrong, but it's close)
- deleted 6y ago[deleted]
- kebman 6y agoI love Cypher too. And PostgreSQL! I wonder how this project compares to Neo4j.
- eurasiantiger 6y agoTake a look at OrientDB’s OSQL.
- simplify 6y agoAgreed, Cypher was the thing I loved most about neo4j.
- simonebrunozzi 6y agoEver tried 4GL on IBM? Way worse than most.
- znpy 6y agoold: https://news.ycombinator.com/item?id=26309560 https://news.ycombinator.com/item?id=26309560
- jeiklo 6y agoThough i appreciate all the hard work people put into this and offer it so generously for free, it kind of saddens me to see yet another property graph database that supports some non-standardized (not really anyway) query language. I would really like to see a free and rdf based triple-store with good SPARQL support and that can be used for serious production workloads. But all the open source activity seems to be in the property-graph camp, with a new product every couple of month, while the high-quality triple stores are all quite pricy.
- jnwatson 6y agoReally, the market has spoken. In relational databases, tables with multiple columns aren't strictly necessary, but practically quite useful. In the same way, property graphs are more useful than triple stores, since common usage patterns want a collection of related properties a lot of the time. Another way to put it is: it is straightforward to map a property graph to a triple store. In most cases, the property graph will have fewer nodes and edges and will operate faster and be easier to maintain.
- kendallgclark 6y agoBenchmarks consistently fail to show this perf advantage. Fair ones anyway. Which makes sense because property graphs and RDF are very similar and mostly differ in terms of syntax, i.e., stuff that good query planners and indexing schemes compile away.
- rambojazz 6y agoWhat does it mean that "tables with multiple columns aren't strictly necessary"? Do you use tables with 1 column?
- nkozyra 6y ago"One sequential primary key field is all the columns anyone will ever need in a database" - Bill Gates
- gorgonzolaoh 6y agoCool Project!
- rajman187 6y agoIt’s always nice to see such efforts around Postgres. I do think it’s very well suited to many needs aside from extreme scales that most won’t deal with. In terms of graphs, there is also an implementation of Tinkerpop which allows using Gremlin, very different in nature to Cypher. http://www.sqlg.org/docs/2.0.1/ http://www.sqlg.org/docs/2.0.1/ NB: I believe cypher can compile to bytecode that runs on the tinkerpop engine which I found interesting
- drodil 6y agoVery ugly code review process in that project in Developer Guidelines
- mdaniel 6y agoAnd braceless if statements are the road to ruin I also chuckled at "Repeat 4 and 5." written in a `<ul>`
- gutbasokchok 6y agoCheck out http://age.apache.org/docs/Apache_AGE_Guide.pdf http://age.apache.org/docs/Apache_AGE_Guide.pdf for details
- csakgw 6y agoThat's a very interesting topic