简体   繁体   中英

Neo4j Causal Cluster Bolt Driver Performance Too Low

We are evaluating Neo4J Enterprise Edition Causal Cluster using Bolt Driver for Java.

We have 3 node Core Cluster.

The performance we saw is too low.

We are creating just 1 node with 2 property 10,00,000 times. When tracked, we are getting 300TPS (ie only 300 nodes are created per second).

OS is Linux, RHEL.

Each core is running with 32GB.

We were estimating close to 50,000 TPS for creation of just 1 node however it is only 300 TPS which is way way way too low.

I am sure we are missing something big.

This function is called 10,00,000 times by a thread pool of 64 threads. Code Snippet:

@Override
    public void createNode() throws InterruptedException {

        try (Session session = RTNeo4j.getInstance().getWriteDriver().session(AccessMode.WRITE)) {
            try (final Transaction tx = session.beginTransaction()) {
                try {

                    tx.run("CREATE (a:Person {name: {name}, id: {id}})",
                            parameters("name", "king", "id", System.currentTimeMillis()));

                    tx.success();

                } catch (Exception e) {

                    e.printStackTrace();
                }
            }
        }

    }

Appreciate quick help for evaluation.

You do not have to create each time a session within a method. Move the creation of the session outside method:

Session session = RTNeo4j.getInstance().getWriteDriver().session(AccessMode.WRITE)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM