title: NoClassDefFoundError when executing a Neo4j Cypher query in Java
body: <p>I tried the following basic example about <a href="http://docs.neo4j.org/chunked/milestone/tutorials-cypher-java.html" rel="nofollow">executing Cypher queries from Java in embedded mode</a> as is, but it shows the errors below:</p>
  
  <p>Code:</p>
  
  <pre><code>package test;
  
  import org.neo4j.cypher.javacompat.ExecutionEngine;
  import org.neo4j.cypher.javacompat.ExecutionResult;
  import org.neo4j.graphdb.GraphDatabaseService;
  import org.neo4j.graphdb.Node;
  import org.neo4j.graphdb.Transaction;
  import org.neo4j.graphdb.factory.GraphDatabaseFactory;
  
  public class Test {
  
      public static void main(String[] args) {
          GraphDatabaseService db = new GraphDatabaseFactory().newEmbeddedDatabase("D:/MI/Tools/neo4j-community-1.9.M02/test2");
          // add some data first, keep id of node so we can refer to it
          long id;
          Transaction tx = db.beginTx();
          try {
              Node refNode = db.createNode();
              id = refNode.getId();
              refNode.setProperty("name", "reference node");
              tx.success();
          } finally {
              tx.finish();
          }
  
          // let's execute a query now
          ExecutionEngine engine = new ExecutionEngine(db);
          ExecutionResult result = engine.execute("start n=node(" + id + ") return n, n.name");
          System.out.println(result.toString());
      }
  }
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>Exception in thread "main" java.lang.NoClassDefFoundError: com/googlecode/concurrentlinkedhashmap/ConcurrentLinkedHashMap$Builder
      at org.neo4j.cypher.internal.LRUCache.&lt;init&gt;(LRUCache.scala:30)
      at org.neo4j.cypher.ExecutionEngine$$anon$1.&lt;init&gt;(ExecutionEngine.scala:91)
      at org.neo4j.cypher.ExecutionEngine.&lt;init&gt;(ExecutionEngine.scala:91)
      at org.neo4j.cypher.javacompat.ExecutionEngine.&lt;init&gt;(ExecutionEngine.java:54)
      at org.neo4j.cypher.javacompat.ExecutionEngine.&lt;init&gt;(ExecutionEngine.java:44)
      at test.Test.main(Test.java:27)
  Caused by: java.lang.ClassNotFoundException: com.googlecode.concurrentlinkedhashmap.ConcurrentLinkedHashMap$Builder
      at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
      at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
      at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
      ... 6 more
  Java Result: 1
  BUILD SUCCESSFUL (total time: 5 seconds)
  </code></pre>
  
  <p>Is there any problem in the code?</p>
  
  <p>(I use neo4j-community-1.9.M02 and NetBeans IDE 7.2.1)</p>
  
  <p>Thanks.</p>