Benchmark Results – ArangoDB vs. Neo4j : ArangoDB up to 8x faster than Neo4j

Introduction

This document presents the benchmark results comparing the ArangoDB’s Graph Analytics Engine (GAE) against Neo4j. The GAE is just one component of ArangoDB’s Data Science Suite. 

This reproducible benchmark aims to provide a neutral and thorough comparison between the two databases, ensuring a fair and unbiased assessment.

We use the wiki-Talk dataset, a widely used, real-world graph dataset derived from the edit and discussion history of Wikipedia

The wiki-Talk dataset encapsulates communication patterns between Wikipedia users, specifically interactions on user talk pages. This dataset is used frequently in benchmarking graph databases and graph analytics systems because of its unique characteristics. The key characteristics of wiki-Talk that make it a highly reliable benchmarking dataset are: Directed Graph, Nodes and Edges, Scale, Temporal Dimension, Sparsity, etc. 

The results demonstrate the efficiency and scalability of each database, and offer a representative benchmark model for organizations evaluating graph databases for their needs.

Benchmark Highlights

The benchmark results reveal several notable insights, particularly highlighting ArangoDB's superior performance in graph analytics tasks compared to Neo4j. Most strikingly:

  • ArangoDB consistently outperformed Neo4j across various graph computation algorithms, with performance improvements that range from 1.3 times to over 8 times faster.
  • This substantial speed advantage is also evident in graph loading times, where ArangoDB demonstrated an impressive 100% advantage in graph loading efficiency vs Neo4j, for the wiki-Talk dataset.

ArangoDB's optimized data storage and retrieval, combined with its advanced query execution and effective use of clustered deployments, also contributed significantly to its superior performance in these scenarios.

These findings underscore:

  • ArangoDB's capability to handle much larger-scale and far faster real-time graph analytics applications.
  • ArangoDB as a much more compelling choice for industries and organizations that require rapid data processing and analysis, such as real-time recommendation systems, social network analysis, fraud detection, and cyber security.

Benchmark Overview

Datasets (wiki-Talk)

We utilized the wiki-Talk dataset, a well-regarded dataset for evaluating graph database performance. The chosen graphs and their details are as follows:

Graphs UsedVerticesEdges
wiki-Talk2,394,3855,021,410

Hardware

All tests were conducted on the same machine with the following specifications:

          OS              Ubuntu 23.10 (64-bit)
          Memory    192 GB (4800 MHz)
          CPU           Ryzen 9 7950X3D (16 Cores, 32 Threads)

Database Configuration

           ***Neo4j***

          Version             5.19.0 (Community Edition)
          Deployment     On-Premise, Single Process

          ***ArangoDB***

         Version                3.12.0-NIGHTLY.20240305 (Community Edition)
         Deployment         On-Premise, Single Process

Graph Analytics Engine (GAE)

        Version                Latest
        Deployment        On-Premise, Single Process (RUST-based, no   multithreading)

Benchmark Configuration

    Two workflows were used to measure performance:

     Workflow A:

  1.  Create the in-memory representation
  2. Execute each algorithm once
  3. Measure the whole process

     Workflow B

  1. Create the in-memory representation
  2. Measure graph creation time
  3. Execute each algorithm individually
  4. Measure computation time

Algorithms Tested

  • Pagerank
  • Weakly Connected Components (WCC)
  • Strongly Connected Components (SCC)
  • Label Propagation

Used Technologies

  • JavaScript Framework: Vitest with tinybench
  • Communication
    • Neo4j: Official Neo4j JS driver ("neo4j-driver": "^5.18.0")
    • GAE: Plain HTTPs requests using Axios ("axios": "^1.6.8")

Benchmark Results

Graph Loading (wiki-Talk)

TaskGAE (sec)Neo4j (sec)Times Faster
Load graph wiki-Talk9.9181.8 x
Load Graph wiki-Talk with Attributes10.719.21.8 x

graph computation

Graph Computation (wiki-Talk)

TaskGAE (sec)Neo4j (sec)Times Faster
Compute PageRank3.810.62.8 x
Compute WCC2.34.51.7 x
Compute SCC3.26.72.1 x
Compute Label Propagation1.5138.5 x

Explanation of Elements

graph loading

Graph Algorithms

  • Pagerank, An algorithm that is used to rank nodes in a graph based on their connections, also commonly used in search engines. 
  • Weakly Connected Components (WCC), which identifies subsets of a graph where any two vertices are connected by paths, ignoring the direction of edges. 
  • Strongly Connected Components (SCC), Identifying subsets of a graph where every vertex is reachable from every other vertex within the same subset. 
  • Label Propagation, a semi-supervised learning algorithm for community detection in graphs, where nodes propagate their labels to their neighbors iteratively.

Reasons for ArangoDB’s Superior Performance

Several factors contribute to ArangoDB's superior performance:

The performance of ArangoDB on the Wiki-Talk dataset is attributed to specific architectural optimizations rather than on raw computational benchmarks. In this scenario, ArangoDB serves as a data storage system, while the computation is handled by the Graph Analytics Engine (GAE). The benchmark focuses on two key stages:

  1. Loading the data into the GAE
  2. Computation of algorithms within the GAE

Graph Loading Times

ArangoDB Side

ArangoDB’s graph loading times are optimized due to two primary factors:

  1.  Parallel Data ExtractionArangoDB’s support for parallel data loading from both single and distributed systems is a big reason for data loading performance advantages. This capability lets teams scale to multiple machines, where increased parallelism gets you faster data transfer. By enabling efficient horizontal scaling, the system achieves significant performance improvements compared to approaches that are limited to sequential or that don’t leverage parallel extractions.
  2.  Projections for Targeted Data TransferProjections allow ArangoDB to transmit only the data attributes required for analysis. So, if only edge IDs and a single attribute are needed, the system  only extracts and transfers these fields, avoiding the overhead of transmitting entire documents. This reduces both the data volume and network latency during graph loading operations.

Graph Analytics Engine (GAE) Side

The GAE is built using RUST, and it processes the transferred data with high efficiency:

  • Efficient Data Representation
    The GAE stores graph data within highly optimized in-memory structures, reducing memory usage while at the same time maintaining extremely fast access speeds. Graphs are immediately ready for computation without unnecessary delays.

Advantages in the Workflow

These features deliver several tangible benefits, as shown during the benchmark:

  1. Fast and Parallel Data Extraction - Parallelism improves speed and scalability. 
  2. Optimized Data Transfer with Projections - Only the required data is transmitted, minimizing overhead. 
  3. Compact and Efficient In-Memory Representation in GA - High-performance graph computation with minimal memory footprint.

Clarifying the Benchmark Scope

It is important to note that the benchmark does not evaluate data insertion times into ArangoDB or computational tasks performed by ArangoDB itself. Instead, it assesses the efficiency of:

  • Loading graph data from ArangoDB into the GAE.
  • The GAE's ability to compute graph algorithms.

By highlighting these stages, the benchmark shows the advantages of ArangoDB’s design in supporting large-scale graph workflows through fast data loading and efficient interaction with the GAE.

Reproducibility of the Benchmark

This benchmark is 100% reproducible, ensuring consistent and verifiable results. These results reflect ArangoDB’s implementation per the precise specifications and configurations mentioned above. We welcome organizations to replicate the benchmark to ensure consistent results. To do this, follow these steps:

  1. First, set up the hardware environment with an Ubuntu 23.10 operating system, 192 GB of memory, and a Ryzen 9 7950X3D CPU.
  2. Install and configure the latest versions of Neo4j and ArangoDB using the provided Docker configurations. Use single-threaded (non-clustered) configurations for both.
  3. Next, utilize the wiki-Talk dataset for testing. Execute the specified graph algorithms (PageRank, WCC, SCC, Label Propagation) using the detailed workflows (A and B) outlined in the benchmark configuration above.
  4. Measure the in-memory graph creation and computation times, and compare the results for both databases. This method ensures that the benchmark can be reliably reproduced in different environments.

PLEASE NOTE: This benchmark requires the installation of the ArangoDB Graph Analytics Engine (GAE). As this code is not open source, please reach out to Corey Sommers at corey.sommers@arangodb.com to receive access to the GAE for the purposes of reproducing this benchmark in your environment (to ensure objectivity of results).

Conclusion

The benchmark results clearly demonstrate ArangoDB's far superior performance over Neo4j in the categories of graph computation and loading tasks. ArangoDB's significant speed advantages - particularly its ability to execute complex algorithms and load large datasets much faster - highlight its optimized architecture and efficient data handling.

These findings make ArangoDB a compelling choice for applications requiring high-performance graph analytics and real-time data processing.

More info...

Gartner Report: Top-Rated Operational Database Management Systems

Firstly, a huge thank you to all our customers that took the time to review ArangoDB for the Gartner Peer Insights “Voice of the Customer”: Operational Database Management Systems Market report. Without your help and assistance, the continued improvements and enhancements we make to our software wouldn’t be possible. Read more

More info...

Multi-Model Benchmark: Round 1 Results | ArangoDB Blog

The latest edition of the NoSQL Performance Benchmark (2018) has been released. Please click here

It’s time for another update of my NoSQL performance blog series. This hopefully concludes the first part of this series with the initial databases ArangoDB, MongoDB, Neo4J and OrientDB and I can now start to check out other databases. I’m getting a lot of requests to test others as well and I’ll try to add them as soon as possible. Pull requests to my repository are also more than welcome. Remember it is all open-source.

The first set of benchmarks was started as a proof that multi-model can compete with specialized solutions and I started with the corresponding top dogs (Neo4J and MongoDB) for graphs and documents. After the first blog post, we were asked by the community to include OrientDB as the other multi-model database, too, which makes sense and therefore I expanded the initial lineup.

Concluding the tests did take a bit longer than expected, because vendors took up the challenge and improved their products with impressive results – as we asked them to do. Still, for each iteration we needed some time to run all tests, see below. However, on the upside, everyone can benefit from the improvements, which is an awesome by-product of the benchmark tests. (more…)

More info...

Improving Databases: Open Source Competitive Benchmark

TL;DR: Our initial benchmark has raised a lot of interest. Initially we wanted to show that multi-model can compete with other solutions. Due to the open and competitive way we have conducted the benchmark, the discussions around it have lead to improvements in all products, better algorithms, faster drivers and better ways to use the databases.

The latest edition of the NoSQL Performance Benchmark (2018) has been released. Please click here

General Setup

From the outset we published all code and data and asked the vendors of all tested products as well as the general public, not only to run the tests on their own machines, but also to suggest improvements in the data models, test code, database configuration, driver usage and server configuration. This lead to a lively discussion, lots of pull requests and even to the release of improved versions of the database products themselves!

This process exceeded all our expectations and is yet another great example of community collaboration not only for fact finding but also for product improvements. Obviously, the same benchmark code will always show slightly different results when run on different hardware, operating systems, network setups and with more or less RAM. Therefore, a reliable result of a benchmark can essentially only be achieved by allowing everybody to run it on their own machines.

The technical setup is described in the above blog post. Let me briefly repeat the key facts.

(more…)

More info...

Performance Comparison: ArangoDB vs MongoDB, Neo4j, OrientDB

The latest edition of the NoSQL Performance Benchmark (2018) has been released. Please click here

My recent blog post “Native multi-model can compete” has sparked considerable interest on HN and other channels. As expected, the community has immediately suggested improvements to the published code base and I have already published updated results several times (special thanks go to Hans-Peter Grahsl, Aseem Kishore, Chris Vest and Michael Hunger).

Please note: An update is available (June ’15) and a new performance test with PostgreSQL added.

Here are the latest figures and diagrams:

chart performance r105

The aim of the exercise was to show that a multi-model database can successfully compete with special players on their own turf with respect to performance and memory consumption. Therefore it is not surprising that quite a few interested readers have asked, whether I could include OrientDB, the other prominent native multi-model database.

(more…)

More info...

Multi-Model Benchmark: Assessing ArangoDB’s Versatility

Claudius Weinberger, CEO ArangoDB

TL;DR Native multi-model databases combine different data models like documents or graphs in one tool and even allow to mix them in a single query. How can this concept compete with a pure document store like MongoDB or a graph database like Neo4j? I myself and a lot of folks in the community asked that question.

So here are some benchmark results: 100k reads → competitive; 100k writes → competitive; friends-of-friends → superior; shortest-path → superior; aggregation → superior.

Feel free to comment, join the discussion on HN and contribute – it’s all on Github.

The latest edition of the NoSQL Performance Benchmark (2018) has been released. Please click here

(more…)

More info...

Bulk Inserts: MongoDB vs CouchDB vs ArangoDB (Dec 2014)

More than two years ago, we compared the bulk insert performance of ArangoDB, CouchDB and MongoDB in a blog post.

The original blog post dates back to the times of ArangoDB 1.1-alpha. We have been asked several times to re-run the tests with the current versions of the databases. So here we go.

(more…)

More info...

Bulk Insert Benchmark Tool | ArangoDB 2012

To easily conduct bulk insert benchmarks with different NoSQL databases, we wrapped a small benchmark tool in PHP. The tool can be used to measure the time it takes to bulk upload data into MongoDB, CouchDB, and ArangoDB using the databases’ bulk documents APIs.
(more…)

More info...

ArangoDB 2012: Additional Results for Mixed Workload

In a comment to the last post, there was a request to conduct some benchmarks with a mixed workload that does not test insert/delete/update/get operations in isolation but when they work together.

To do this, I put together a quick benchmark that inserts 10,000 documents, and after each insert either

  • directly fetches the inserted document (i.e. insert / get),
  • updates the inserted documents and retrieves it (i.e. insert / update / get), or
  • deletes it (i.e. insert / delete)

The three cases are alternated deterministically, meaning each case occurs with the same frequency and in the same order. It’s probably still not the best ever test case, but at least it reflects a mixed read and write workload.

The document ids used in the test were monotically increasing integers, starting from some base value. That means no random values were used.

The test was repeated for 100,000 documents as well. The dataset still fully fits in RAM. The tests were run in the same environment as the previous tests so one can compare them.

The results are in line with the results shown in the previous post. Here’s the chart with the results of the 10,000 documents benchmark:

times combined 10000

And here are the tests result for the 100,000 documents benchmark:

times combined 100000
More info...

ArangoDB vs. CouchDB Benchmarking | ArangoDB 2012

A side-effect of measuring the impact of different journal sizes was that we generated some performance test results for CouchDB, too. They weren’t included in the previous post because it was about journal sizes in ArangoDB, but now we think it’s time to share them.
(more…)

More info...

Get the latest tutorials,
blog posts and news: