title: Why neo4j-ogm not saves relations to embedded neo4j-database?
body: <p>I try to get a working system of an embedded tomcat-server with spring-boot, joinfaces and the embedded <a href="https://neo4j.com/" rel="nofollow noreferrer">neo4j</a>-graph-database with the object-mapping ogm. Everything seems to work fine. I commit my sources to <a href="https://svn.riouxsvn.com/circlead-embedd/circlead-embedded/" rel="nofollow noreferrer">https://svn.riouxsvn.com/circlead-embedd/circlead-embedded/</a> </p>
  
  <p>The problem is that all <a href="https://github.com/neo4j/neo4j-ogm" rel="nofollow noreferrer">neo4j-ogm</a>-examples (see i.e. <a href="http://www.hascode.com/2016/07/object-graph-mapping-by-example-with-neo4j-ogm-and-java/" rel="nofollow noreferrer">http://www.hascode.com/2016/07/object-graph-mapping-by-example-with-neo4j-ogm-and-java/</a>) show that @Relationship works with ogm. But when i test it with</p>
  
  <pre><code>@NodeEntity
  public abstract class GenericNode&lt;T&gt; implements INode&lt;T&gt; {
  
      @GraphId
      public Long id;
  
      @SuppressWarnings("unused")
      private void setId(Long id) {
          this.id = id;
      }
  
      public String label;
  
      @Relationship(type = "PARENT_OF", direction = Relationship.INCOMING)
      public Set&lt;T&gt; parents = new HashSet&lt;T&gt;();
  
      @Relationship(type = "CHILD_OF", direction = Relationship.OUTGOING)
      public Set&lt;T&gt; children = new HashSet&lt;T&gt;();
  
      ...
  </code></pre>
  
  <p>then all relations seem not to be written in the database, because the lines</p>
  
  <pre><code>    Role rp = new Role("Role 1");
      Role rc = new Role("Role 2");
      rc.addParent(rp);
      session.save(rc);
      Iterable&lt;Role&gt; roles = session.query(Role.class, "MATCH (x) RETURN x;", Collections.&lt;String, Object&gt;emptyMap());
  
      for (Role role : roles) {
          System.out.println(role);
      }
  </code></pre>
  
  <p>show in the console that the relations of the database are missing. It seems that only in the active session-relations are found. After a server-reboot all relations are missing.</p>
  
  <pre><code>Role [id=52, label=Role 2, parents=[]]
  Role [id=53, label=Role 1, parents=[]]
  Role [id=54, label=Role 1, parents=[]]
  Role [id=55, label=Role 2, parents=[54]]
  </code></pre>
  
  <p>I have no clue what occurs this kind of error. I use neo4j-ogm 2.1.2 and neo4j 3.1.3.</p>
  
  <p>Any idea?</p>