1 Reply Latest reply on Dec 4, 2007 1:11 PM by Manik Surtani

    What replicates in JBC 1.4?

    Jorge Morales Master

      Hi,
      We have a large application, with large amount of data stored in cache. For some data, we store it as nodes, for some other data, we store it as attributes, in order to find a good compromise between number of nodes, data in each node. We use SYNC_REPL to replicate data between our 2 node cluster, and use multicast for replication.

      I would like to know?


      For a 10000 atribute node, what data is replicating when we change on of the attributes? Is it replicating the whole node data, or only the changed attribute?
      What is faster, access to a 10000 attribute node, or access to 10000 nodes single attributed?
      Would REPL_ASYNC signify a performance gain?
      Would the be deadlocking issues when more threads access cache. It seems our application doesn`t scale clients very well. (I have already seen http://www.jboss.com/index.html?module=bb&op=viewtopic&t=122400 which I gues will not be backported to 1.4)
      Is it better to set up TCP replication?
      Is there any performance tunning guide?


      Thanks, like always.

        • 1. Re: What replicates in JBC 1.4?
          Manik Surtani Master

           

          "jorgemoralespou_2" wrote:
          For a 10000 atribute node, what data is replicating when we change on of the attributes? Is it replicating the whole node data, or only the changed attribute?


          It depends. It really replicates a method call, so if you do:

          Node n; // contains 100000 attribs
          Map m = generateData(); // creates a map with 10000 attribs
          n.putAll(m);
          


          The above will replicate a map with 10000 attribs. But if you do:

          Node n; // contains 100000 attribs
          n.put("hello", "world");
          


          The above will replicate the single key/value pair.


          "jorgemoralespou_2" wrote:
          What is faster, access to a 10000 attribute node, or access to 10000 nodes single attributed?


          Again, depends. If your tree is deep, walking the tree will become a performance overhead. Also depends on your data access patterns: if you do a lot of bulk updates (node.putAll()) having more attribs in a single node would be faster, but will reduce concurrency.

          "jorgemoralespou_2" wrote:
          Would REPL_ASYNC signify a performance gain?


          Yes, in so far as you don't block on replication completing. Also means you scale better as your cluster size increases.

          "jorgemoralespou_2" wrote:
          Would the be deadlocking issues when more threads access cache.


          Possibly. See Optimistic Locking.

          "jorgemoralespou_2" wrote:
          Is it better to set up TCP replication?


          Depends on your network. With Buddy Replication this could be better.

          "jorgemoralespou_2" wrote:
          Is there any performance tunning guide?


          Not yet. :-(