JCR clustering configuration to JCR 1.10.4, 1.11.2

Instructions for JCR 1.11.2 and 1.10.4

For version 1.11 the replication requires JGroups 2.5.2.

In fact, this configuration also work since 1.10.4.
<component> 
    <type>org.exoplatform.services.jcr.ext.replication.ReplicationService</type> 
    <init-params> 
      <values-param> 
          <name>repositories</name> 
            <value>repository</value> 
      </values-param> 
      <properties-param> 
        <name>replication-properties</name> 
          <property name="enabled" value="true"/> 
          <property name="mode" value="persistent"/> <!-- {persistent, proxy} -->
          <property name="bind-ip-address" value="192.168.0.15"/> 
          <property name="channel-config" value="TCP(oob_thread_pool.queue_max_size=100;thread_naming_pattern=cl;use_concurrent_stack=true;oob_thread_pool.rejection_policy=Run;discard_incompatible_packets=true;thread_pool.max_threads=40;oob_thread_pool.enabled=false;oob_thread_pool.max_threads=20;loopback=false;oob_thread_pool.keep_alive_time=5000;thread_pool.queue_enabled=false;oob_thread_pool.queue_enabled=false;max_bundle_size=64000;thread_pool.queue_max_size=100;thread_pool.enabled=false;enable_diagnostics=true;max_bundle_timeout=30;oob_thread_pool.min_threads=8;use_incoming_packet_handler=true;thread_pool.rejection_policy=Run;bind_addr=$bind-ip-address;thread_pool.min_threads=8;thread_pool.keep_alive_time=5000;enable_bundling=true):MPING(timeout=2000;num_initial_members=8;mcast_port=34526;mcast_addr=224.0.0.1):FD(timeout=2000;max_tries=5;shun=true):FD_SOCK:VERIFY_SUSPECT(timeout=1500):pbcast.NAKACK(max_xmit_size=60000;print_stability_history_on_failed_xmit=true;use_mcast_xmit=false;gc_lag=0;discard_delivered_msgs=true;retransmit_timeout=300,600,1200,2400,4800):pbcast.STABLE(stability_delay=1000;desired_avg_gossip=50000;max_bytes=8000000):pbcast.GMS(print_local_addr=true;join_timeout=3000;view_bundling=true;join_retry_timeout=2000;shun=true;merge_leader=true;reject_join_from_existing_member=true)"/> 
          <property name="recovery-dir" value="../temp/replication/recovery"/> 
          <property name="node-name" value="cluster_node2"/> 
          <property name="other-participants" value="cluster_node1;cluster_node3"/> 
          <property name="wait-confirmation" value="2000"/> 
      </properties-param> 
      <properties-param>
        <name>replication-priority-properties</name>
          <property name="priority-type" value ="dynamic"/> <!-- {static, dynamic} --> 
          <property name="node-priority" value="100"/> <!-- max == 100 -->
      </properties-param>
    </init-params> 
  </component>

ParameterDescriptionValue
enabledenable/disable replicationtrue or false
modetype of replicationpersistent or proxy
bind-ip-addressIP address of the local network interface to use for replicationIP address
channel-configJGroups configurationSee the JGroups Docs
recovery-dira path to the directory for recovery informationpath
node-namethe name of this nodestring
other-participantslist of names of other cluster participantscomma separated list of cluster names
wait-conformationtime to wait for acknowledgement on successful preservation ChangesLog, set in millisecondsx ms
priority-typetype of priority{static or dynamic}
node-prioritythe priority value{0..100}, max = 100

Warning: The value of 'node-priority' for each participant should not be duplicated in cluster. If 'node-priority' is duplicated, then all participants of cluster will be go to the READ-ONLY.

The properties 'replication-priority-properties' was not supported since version JCR 1.11.2 (and only version 1.10.4).

Instruction for JCR 1.11.2 (1.10.4) to proxy replication

The priorities mechanism was changed in 1.11.2 (and 1.10.4) to proxy replication.

The JCR 1.11.2 (1.10.4) allows use same configuration to all participants in proxy replication.

<component>
    <type>org.exoplatform.services.jcr.ext.replication.ReplicationService</type>
    <init-params>
      <value-param>
        <name>force-xml-configuration</name>
          <value>true</value>
      </value-param>
      <values-param>
          <name>repositories</name>
            <value>repository</value>
      </values-param>
      <properties-param>
        <name>replication-properties</name>
          <property name="enabled" value="true"/>
          <property name="mode" value="proxy"/>
          <property name="bind-ip-address" value="${exo.bind.ip.address}"/>

<property name="channel-config"
value="TCP(start_port=7700;oob_thread_pool.queue_max_size=100;thread_naming_pattern=cl;use_concurrent_stack=true;oob_thread_pool.rejection_policy=Run;discard_incompatible_packets=true;thread_pool.max_threads=40;oob_thread_pool.enabled=false;oob_thread_pool.max_threads=20;loopback=false;oob_thread_pool.keep_alive_time=5000;thread_pool.queue_enabled=false;oob_thread_pool.queue_enabled=false;max_bundle_size=64000;thread_pool.queue_max_size=100;thread_pool.enabled=false;enable_diagnostics=true;max_bundle_timeout=30;oob_thread_pool.min_threads=8;use_incoming_packet_handler=true;thread_pool.rejection_policy=Run;bind_addr=$bind-ip-address;thread_pool.min_threads=8;thread_pool.keep_alive_time=5000;enable_bundling=true):TCPPING(initial_hosts=192.168.0.245[7700],192.168.0.246[7700];port_range=5;timeout=3000;num_initial_members=2):FD(timeout=2000;max_tries=5;shun=true):FD_SOCK:VERIFY_SUSPECT(timeout=1500):pbcast.NAKACK(max_xmit_size=60000;print_stability_history_on_failed_xmit=true;use_mcast_xmit=false;gc_lag=0;discard_delivered_msgs=true;retransmit_timeout=300,600,1200,2400,4800):pbcast.STABLE(stability_delay=1000;desired_avg_gossip=50000;max_bytes=8000000):pbcast.GMS(print_local_addr=true;join_timeout=3000;view_bundling=true;join_retry_timeout=2000;shun=true;merge_leader=true;reject_join_from_existing_member=true)"/>
          <property name="channel-name" value="OnlineRepCh_DMS_2"/>
          <property name="recovery-dir" value="../temp/replication/recovery"/>
          <property name="wait-confirmation" value="2000"/>
      </properties-param>
    </init-params>
  </component>

The members is definitions in TCPPING the property 'initial_hosts'. List initial_hosts should contain all of the participants.

TCPPING(initial_hosts=192.168.0.245[7700],192.168.0.246[7700];port_range=5;timeout=3000;num_initial_members=2)

In JCR 1.11.2 and later have a parameter "channel-name". This parameter allows working few clusters in one network with same configuration of JGroups.

Tags:
Created by Alex Reshetnyak on 07/27/2009
Last modified by Alex Reshetnyak on 10/28/2009

Products

generated on Thu Sep 02 15:26:04 UTC 2010

eXo Optional Modules

eXo Core Foundations


Copyright (c) 2000-2010. All Rights Reserved - eXo platform SAS
2.4.30451