Implementation of object cache in Neo4j 3.2.3











up vote
1
down vote

favorite












I have read this post "Understanding of Neo4j object cache", but can't find 'NodeImpl' any more in the source code of Neo4j 3.2.3.



I tried some code to track down to the implementation of Neo4j, but fail to find access to any cache other than page cache. I tried to get property of same node twice, expect to hit the cache when shoot the second query.



            Node n = db.getNodeById(0);
n.getProperty("name");
String name = (String) n.getProperty("name");
System.out.println("name: " + name);


There is a lot of 'InstanceCache' inside 'StoreStatement', but as the comment implies, instance cache is used for single object, not used for connection between node and relationship as described here in 'An overview of Neo4j Internals'.



My question is:




  1. What's the implementation of object cache inside neo4j 3.2.3 ?

  2. Is there anything newer for internals of neo4j ? The slide I got is published 6 year ago.










share|improve this question


























    up vote
    1
    down vote

    favorite












    I have read this post "Understanding of Neo4j object cache", but can't find 'NodeImpl' any more in the source code of Neo4j 3.2.3.



    I tried some code to track down to the implementation of Neo4j, but fail to find access to any cache other than page cache. I tried to get property of same node twice, expect to hit the cache when shoot the second query.



                Node n = db.getNodeById(0);
    n.getProperty("name");
    String name = (String) n.getProperty("name");
    System.out.println("name: " + name);


    There is a lot of 'InstanceCache' inside 'StoreStatement', but as the comment implies, instance cache is used for single object, not used for connection between node and relationship as described here in 'An overview of Neo4j Internals'.



    My question is:




    1. What's the implementation of object cache inside neo4j 3.2.3 ?

    2. Is there anything newer for internals of neo4j ? The slide I got is published 6 year ago.










    share|improve this question
























      up vote
      1
      down vote

      favorite









      up vote
      1
      down vote

      favorite











      I have read this post "Understanding of Neo4j object cache", but can't find 'NodeImpl' any more in the source code of Neo4j 3.2.3.



      I tried some code to track down to the implementation of Neo4j, but fail to find access to any cache other than page cache. I tried to get property of same node twice, expect to hit the cache when shoot the second query.



                  Node n = db.getNodeById(0);
      n.getProperty("name");
      String name = (String) n.getProperty("name");
      System.out.println("name: " + name);


      There is a lot of 'InstanceCache' inside 'StoreStatement', but as the comment implies, instance cache is used for single object, not used for connection between node and relationship as described here in 'An overview of Neo4j Internals'.



      My question is:




      1. What's the implementation of object cache inside neo4j 3.2.3 ?

      2. Is there anything newer for internals of neo4j ? The slide I got is published 6 year ago.










      share|improve this question













      I have read this post "Understanding of Neo4j object cache", but can't find 'NodeImpl' any more in the source code of Neo4j 3.2.3.



      I tried some code to track down to the implementation of Neo4j, but fail to find access to any cache other than page cache. I tried to get property of same node twice, expect to hit the cache when shoot the second query.



                  Node n = db.getNodeById(0);
      n.getProperty("name");
      String name = (String) n.getProperty("name");
      System.out.println("name: " + name);


      There is a lot of 'InstanceCache' inside 'StoreStatement', but as the comment implies, instance cache is used for single object, not used for connection between node and relationship as described here in 'An overview of Neo4j Internals'.



      My question is:




      1. What's the implementation of object cache inside neo4j 3.2.3 ?

      2. Is there anything newer for internals of neo4j ? The slide I got is published 6 year ago.







      neo4j






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 9 at 10:41









      sel-fish

      3,16821131




      3,16821131
























          1 Answer
          1






          active

          oldest

          votes

















          up vote
          2
          down vote



          accepted










          The Object Cache doesn't exist anymore in Neo4j (since version 3.0 from what I remember), there is only the page cache.



          Slides from Tobias that explain the graph storage are still correct.






          share|improve this answer





















          • i saw that there is a field named 'needsCacheInvalidation' in TransactionApplicationMode, so that's for the purpose to invalidate page cache ?
            – sel-fish
            Nov 9 at 10:59










          • I think so ....
            – logisima
            Nov 9 at 13:27











          Your Answer






          StackExchange.ifUsing("editor", function () {
          StackExchange.using("externalEditor", function () {
          StackExchange.using("snippets", function () {
          StackExchange.snippets.init();
          });
          });
          }, "code-snippets");

          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "1"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














           

          draft saved


          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53224146%2fimplementation-of-object-cache-in-neo4j-3-2-3%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          2
          down vote



          accepted










          The Object Cache doesn't exist anymore in Neo4j (since version 3.0 from what I remember), there is only the page cache.



          Slides from Tobias that explain the graph storage are still correct.






          share|improve this answer





















          • i saw that there is a field named 'needsCacheInvalidation' in TransactionApplicationMode, so that's for the purpose to invalidate page cache ?
            – sel-fish
            Nov 9 at 10:59










          • I think so ....
            – logisima
            Nov 9 at 13:27















          up vote
          2
          down vote



          accepted










          The Object Cache doesn't exist anymore in Neo4j (since version 3.0 from what I remember), there is only the page cache.



          Slides from Tobias that explain the graph storage are still correct.






          share|improve this answer





















          • i saw that there is a field named 'needsCacheInvalidation' in TransactionApplicationMode, so that's for the purpose to invalidate page cache ?
            – sel-fish
            Nov 9 at 10:59










          • I think so ....
            – logisima
            Nov 9 at 13:27













          up vote
          2
          down vote



          accepted







          up vote
          2
          down vote



          accepted






          The Object Cache doesn't exist anymore in Neo4j (since version 3.0 from what I remember), there is only the page cache.



          Slides from Tobias that explain the graph storage are still correct.






          share|improve this answer












          The Object Cache doesn't exist anymore in Neo4j (since version 3.0 from what I remember), there is only the page cache.



          Slides from Tobias that explain the graph storage are still correct.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Nov 9 at 10:51









          logisima

          4,8971926




          4,8971926












          • i saw that there is a field named 'needsCacheInvalidation' in TransactionApplicationMode, so that's for the purpose to invalidate page cache ?
            – sel-fish
            Nov 9 at 10:59










          • I think so ....
            – logisima
            Nov 9 at 13:27


















          • i saw that there is a field named 'needsCacheInvalidation' in TransactionApplicationMode, so that's for the purpose to invalidate page cache ?
            – sel-fish
            Nov 9 at 10:59










          • I think so ....
            – logisima
            Nov 9 at 13:27
















          i saw that there is a field named 'needsCacheInvalidation' in TransactionApplicationMode, so that's for the purpose to invalidate page cache ?
          – sel-fish
          Nov 9 at 10:59




          i saw that there is a field named 'needsCacheInvalidation' in TransactionApplicationMode, so that's for the purpose to invalidate page cache ?
          – sel-fish
          Nov 9 at 10:59












          I think so ....
          – logisima
          Nov 9 at 13:27




          I think so ....
          – logisima
          Nov 9 at 13:27


















           

          draft saved


          draft discarded



















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53224146%2fimplementation-of-object-cache-in-neo4j-3-2-3%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Schultheiß

          Verwaltungsgliederung Dänemarks

          Liste der Kulturdenkmale in Wilsdruff