Nodes 2020 Extended

I was the first speaker at Nodes 2020 Extended.

My Talk at Nodes 2020 Extended

This is the first time I have done an event that was live streamed. It was a bit odd having two different streams being shared at the same time (video + audio on one) and the screen on the other.

Thanks to @ElLazal and @nsmith_piano for hosting.

I almost got caught out by the demo gods: I had installed Neo4j 4 at the conference a couple of weeks ago and found that my utility will need some updates before it will work with that version. Thankfully I was able to quickly debug this using a docker image. It’s possible to create a Neo4j 3.5 db in Neoj4j which saved the day.

Contentful to Neo4j in Elixir

I just finished an initial port of my neo4j to contentful library from Node to Elixir.

This is the same utility but in a very different language. It’s not quite as polished as the Node version (but won’t take long to catch up).

Issues that I have had during the port:

  • My machine had a very old erlang implementation (I had installed this when reading the Erlang chapter of 7 languages in 7 weeks – over 7 years ago) which broke HTTPoison, a fairly common HTTP library. The errors pointed to HTTPoison not working on a windows machine (which I have found to not be true).
  • The Contentful Elixir bindings are not very advanced. They don’t return the total number of items that you are paging through. It was not difficult to use the api directly.
  • There are lots of Elixir bindings for Neo4j. Very few of them are clearly documented for writing to Neo4j. Eventually I landed on bolt_sips. Bolt is too primitive, neo4j_sips uses a very old version of HTTPoison.

The Elixir error messages are incredibly clear.

Credo is great for ensuring best practices are applied.

Functional programming allows you to test real code without mocks or spend time fighting promises.

iex is a great REPL environment. You can recompile a module and carry on without restarting everything.

The code is self documenting. This is the top level method:

|> read_all_entries
|> process_contentful
|> write_to_neo4j
VSCode is a great editor for elixir. It’s great from the command line
code .
The above will open vscode on the project in the current directory.