axelson

axelson

Scenic Core Team

Posting a little bit late today but here you go:

ElixirConf 2017 - Elixir + Neo4j - Regina Imhoff

Neo4j is a non-relational graph database with its own query language, Cypher, which means it doesn’t work with Ecto. However, graph databases are great at modeling social networks. You will be learning how to combine Elixir Phoenix with Neo4j to make a clone of a popular social networking site with real time updates to the social graph.

Audience: Intermediate

All talks are available in the Elixir Conf 2017 Talks List or via the elixirconf2017 tag

Showing Posts 1 to 10

josevalim

josevalim

Creator of Elixir

I have always kept an eye on graph databases and it is really exciting to see some work in using them directly from Elixir!

AstonJ

AstonJ

I’m really interested in graph dbs too and I watched most of this talk when it was first uploaded. Great talk Regina, if you are reading this please join up as I might need to pick your brains one day :lol:

JEG2

JEG2

Author of Designing Elixir Systems with OTP

I agree that the graph databases are interesting and this was a solid introduction. I did wonder if skipping Ecto in this case could make interactions more natural.

AstonJ

AstonJ

I love the idea of using separate DBs for different components of your app - so say Postgres for a registration system, Neo4J for a user r/ships system etc

I’m hoping @PragDave will cover something like this in his next course as I’d love to see how his approach would tie something like this together.

WolfDan

WolfDan

I tried to integrate separate databases for that but at the end of the day you end up having mostly the same data in the two databases… So why don’t use a graph database for all? IMO

kylethebaker

kylethebaker

I really like the query syntax, it somewhat isomorphic to the graph relationships themselves, with the arrow and the ‘edges’ (-).

MATCH (p:User)-[:OWNS]->(y:yard)-[*]-(q:User)

The wildcard is particularly cool, how it cuts out all of the inner joins. Basically it’s saying “Use any path/relationship you can find to get from PointA to PointB”. I wonder if it’s possible to do a sort of “meta query” where you can have it show you all of the relationships it’s traversed, maybe something like MATCH (f:Foo)-[r:*]-(b:Bar) RETURN r?

AstonJ

AstonJ

Primarily because different types of DBs have different strengths and weaknesses. And since Elixir makes it much easier to build your app as a series of components, it, to me at least, makes sense to make full use of that; I really really like the idea of having independent systems that are built without having to make compromises that you might have to otherwise.

What kind of data was being duplicated in your app/s?

WolfDan

WolfDan

Well is and app that I’m working my self, kind of little “startup”, basically a social network (I’m a n00b so all this is based in my opinion and experience, I have never worked on a real project before, any opinion or suggestion is welcome!)

At first time I decided to use simply Postgre for all my my project (pretty robust, amazing search features etc…), but after see this talk I decided to use graph databases because it really fist to what I’m doing and make the work easily, so I decided to use Postgre and a Graph database called Dgraph

So I begin to work on it, creating some data and make a sketch of what I want to, but I end up with this “problems”:

  • I need a way to recognize the data that I need in the two databases, so I need the same identifiers (duplicate data)

  • I’m working with Abshinte so are Graphql queries to get the data, since get relationships from Graphql queries are pretty easy, I needed a way to query the main object requested and the relationships, so I saw two options:

    • Parse the Graphql query and query the relationships to graph database, after that construct a SQL query to send it into Postgres (here I think you need to join data etc so what is the point to use a graph database) and send back the data
    • Save directly the same data in the Graph database and query the relationships with the requested data, and just query the basic data of the main object to Postgres database (duplicate data)

    At my opinion the second option the second option was easier

  • If I wanted to use the Graph database as a search I need to add all the data that need to query the result as wanted (again duplicate data)

  • You can build cool things with Graph databases like recommendation systems and so… Need to have the same data in the two databases too to make the feature work correctly

The problem with two databases and duplicate data is maintain the same state in the two databases, so what if one fail if the other no when you update data etc…

At this point looks reasonable to me just use the Graph database, but I haven’t yet made a final decision, as mention before I’m a n00b so possibly I’m wrong on all that I said or a few things, I hope to be corrected if that is the case


Feel free to correct any grammatical problem

AstonJ

AstonJ

If you want to build your app as a series of components, I highly recommend PragDave’s online course - it has given me a huge insight into this sort of architecture and if you’re interested in this too, I think you will love the course just as much as I did :003:

WolfDan

WolfDan

I would really love to acquire the course since was released, but unfortunately I do not have any way to acquire it, I am still quite young and that amount of money is a lot in my country ^^’

Where Next? Top

Trending in Talks Top

alexslade
This is a thread to organise resources while we wait for official posting of videos. I’ve committed to keeping this post updated, please ...
New
bartblast
This is the follow-up to my ElixirConf EU talk in Malaga, which was mostly about the local-first problem and where sync engines stand on ...
New
CodeSync
What if you could build production-ready RAG entirely in Elixir? George Guimarães, ElixirConfEU 2026 https://www.youtube.com/watch?v=tNB...
New
CodeSync
The Everything App - Lars Wikman | ElixirConf EU 2026 Comments welcome! View the <span class="hashtag-icon-placeholder"><...
New
CodeSync
Model the work: Real Life workloads with Ash &amp; Oban - Zach Daniel | ElixirConf EU 2026 https://www.youtube.com/watch?v=ZhUfURGmlqY ...
New
CodeSync
Kafka-Backed Elixir at Scale - Anton Borisov, Piotr Rybarczyk | ElixirConf EU 2026 Comments welcome! View the <span class...
New
CodeSync
Building Real-Time AI Agents with Elixir - Kimutai Kiprotich | ElixirConf EU 2026 https://www.youtube.com/watch?v=XSXk0YE2New Comments...
New

Other Trending Topics Top

GenericJam
Edit: 2026 May 15 - This post is archived. Mob is alive!! Main docs: mob v0.7.11 — Documentation A bit of explanation for the slightly c...
New
JesseHerrick
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
mudasobwa
I am happy to introduce the very α version of the new programming language compiled to BEAM. Welcome Cure. It has literally three kille...
New
garrison
Hobbes is a low-level distributed database for the Elixir programming language. Hobbes provides a simple, safe, and scalable storage lay...
New
budgie
A little off-topic, but I feel like people here have a good head on their shoulders. I used to be quite good at making software. Was luc...
New
KristerV
Hey. Is there anyone here who creates agents in their apps? Not talking about using agents, but creating them. I’m finding it pretty diff...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews