PooledDriver { public Session newSession() { return driver.session(); } PooledDriver(String uri, String user, String pwd); Session newSession(); Session newReadonlySession();  }
@Test public void driverTest() throws Exception { try (Session session = pooledDriver.newSession()) { StatementResult result = session.run("MATCH (n) RETURN count(*) as total_nodes"); long total = result.single().get("total_nodes").asLong(); System.out.println(total); } }