Hi,
 I am getting following error when running the mb 3.0 in cluster mode with
mysql.

Cluster setup - 4 nodes mb and mysql server












































































































*Exception during startup: java.lang.Exception:
org.wso2.andes.kernel.AndesException: Connecting to database failed with
jndi lookup : jdbc/MySQLMessageStore. data source username : root. SQL
Error message : com.mysql.jdbc.Driverjava.lang.Exception:
org.wso2.andes.kernel.AndesException: Connecting to database failed with
jndi lookup : jdbc/MySQLMessageStore. data source username : root. SQL
Error message : com.mysql.jdbc.Driver    at
org.wso2.andes.server.registry.ApplicationRegistry.initialise(ApplicationRegistry.java:266)
at
org.wso2.andes.server.registry.ApplicationRegistry.initialise(ApplicationRegistry.java:147)
at org.wso2.andes.server.Broker.startupImpl(Broker.java:153)    at
org.wso2.andes.server.Broker.startup(Broker.java:114)    at
org.wso2.andes.server.Main.startBroker(Main.java:218)    at
org.wso2.andes.server.Main.execute(Main.java:207)    at
org.wso2.andes.server.Main.<init>(Main.java:48)    at
org.wso2.andes.server.Main.main(Main.java:41)    at
org.wso2.carbon.andes.internal.QpidServiceComponent.startAndesBroker(QpidServiceComponent.java:330)
at
org.wso2.carbon.andes.internal.QpidServiceComponent.setHazelcastInstance(QpidServiceComponent.java:232)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)    at
org.eclipse.equinox.internal.ds.model.ComponentReference.bind(ComponentReference.java:376)
at
org.eclipse.equinox.internal.ds.model.ServiceComponentProp.bindReference(ServiceComponentProp.java:432)
at
org.eclipse.equinox.internal.ds.InstanceProcess.dynamicBind(InstanceProcess.java:416)
at
org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:334)
at
org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
at
org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at
org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at
org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:451)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:950)
at
org.wso2.carbon.core.clustering.hazelcast.HazelcastClusteringAgent.init(HazelcastClusteringAgent.java:223)
at
org.wso2.carbon.core.util.ClusteringUtil.enableClustering(ClusteringUtil.java:38)
at
org.wso2.carbon.core.internal.StartupFinalizerServiceComponent.completeInitialization(StartupFinalizerServiceComponent.java:174)
at
org.wso2.carbon.core.internal.StartupFinalizerServiceComponent.serviceChanged(StartupFinalizerServiceComponent.java:285)
at
org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at
org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at
org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:451)
at
org.wso2.carbon.throttling.agent.internal.ThrottlingAgentServiceComponent.registerThrottlingAgent(ThrottlingAgentServiceComponent.java:123)
at
org.wso2.carbon.throttling.agent.internal.ThrottlingAgentServiceComponent.activate(ThrottlingAgentServiceComponent.java:100)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)    at
org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260)
at
org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146)
at
org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:347)
at
org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
at
org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
at
org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
at
org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
at
org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at
org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at
org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:451)
at
org.wso2.carbon.core.init.CarbonServerManager.initializeCarbon(CarbonServerManager.java:517)
at
org.wso2.carbon.core.init.CarbonServerManager.start(CarbonServerManager.java:219)
at
org.wso2.carbon.core.internal.CarbonCoreServiceComponent.activate(CarbonCoreServiceComponent.java:88)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)    at
org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260)
at
org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146)
at
org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:347)
at
org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
at
org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
at
org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
at
org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
at
org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
at
org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at
org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
at
org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
at
org.eclipse.equinox.http.servlet.internal.Activator.registerHttpService(Activator.java:81)
at
org.eclipse.equinox.http.servlet.internal.Activator.addProxyServlet(Activator.java:60)
at
org.eclipse.equinox.http.servlet.internal.ProxyServlet.init(ProxyServlet.java:40)
at
org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.init(DelegationServlet.java:38)
at
org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1279)
at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1192)
at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1087)
at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5210)
at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5493)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
at
org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)    at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)*

I have attached the configuration files.
What may be the problem with my configuration? Can someone help on this ?

Thanks

Regards,
Megala Uthayakumar
*Software Engineering Intern *| *WSO2 Lanka*
Mobile : +94 779 967 122
Tel      : +94 112 733 667
E-mail :  [email protected]
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
  ~ Copyright (c) 2014, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
  ~
  ~ WSO2 Inc. licenses this file to you under the Apache License,
  ~ Version 2.0 (the "License"); you may not use this file except
  ~ in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~    http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing,
  ~ software distributed under the License is distributed on an
  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  ~ KIND, either express or implied. See the License for the
  ~ specific language governing permissions and limitations
  ~ under the License.
  -->

<!-- This is the root configuration file of WSO2 Message Broker (MB). Links to configurations of 
associated libraries are also specified here. 

[Note for developers] - If you intend to rename or modify a property name, remember to update 
relevant, org.wso2.andes.configuration.enums.AndesConfiguration, enum value using the Xpath 
expression of the property. -->
<broker>

    <!--Paths of externally organized configurations specific to Andes component (Qpid configurations
    are referred by Qpid component separately. (MB_HOME/repository/conf/advanced/qpid-config.xml)-->
    <links>
    </links>

    <coordination>
        <!-- You can override the cluster node identifier of this MB node using the nodeID. 
        If it is left as "default", the default node ID will be generated for it. (Using IP + UUID).
        The node ID of each member should ALWAYS be unique.-->
        <nodeID>default</nodeID>

        <!-- Thrift is used to maintain and sync slot (message groups) ranges between MB nodes. -->
        <thriftServerHost>localhost</thriftServerHost>
        <thriftServerPort>7611</thriftServerPort>
    </coordination>

    <!-- You can enable/disable specific messaging transports in this section. By default all 
    transports are enabled. This section also allows you to customize the messaging flows used 
    within WSO2 MB. NOT performance related, but logic related. -->
    <transports>
        <!-- In a clustered setup this should be updated with the IP address of this node
        Setting the value to 127.0.0.1 in a clustered setup is wrong. Please note that this is 
        the address exposed by the server. NOT the hostname inferred from carbon.xml -->
        <bindAddress>10.100.4.40</bindAddress>

        <amqp enabled="true">
            <!-- most of the AMQP configurations reside in qpid-config.xml since we inherit the Qpid
            messaging model during AMQP.-->
            <port>5672</port>
            <sslPort>8672</sslPort>
            <sendExpiredMessagesToDLC>false</sendExpiredMessagesToDLC>
            <maximumRedeliveryAttempts>10</maximumRedeliveryAttempts>
            <allowSharedTopicSubscriptions>false</allowSharedTopicSubscriptions>
        </amqp>
        <mqtt enabled="true">
            <port>1883</port>
            <!-- put proper default SSL port -->
            <sslPort>8883</sslPort>
            <!-- These two properties are temporary. Ideally, MQTT should use carbon users. -->

            <!--Ring buffer size of MQTT inbound event disruptor. Default is set to 32768 (1024 * 32)
            Having a large ring buffer will have a increase memory usage and will improve performance
            and vise versa -->
            <inboundBufferSize>32768</inboundBufferSize>

            <!--Ring buffer size of MQTT delivery event disruptor. Default is set to 32768 (1024 * 32)
            Having a large ring buffer will have a increase memory usage and will improve performance
            and vise versa -->
            <deliveryBufferSize>32768</deliveryBufferSize>
            

            <security>
                   <!--
                       Instructs the MQTT server whether clients should always send credentials
                       when establishing a connection.
                       Possible values:
                        OPTIONAL: This is the default value. MQTT clients may or may not send 
                                  credentials. If a client sends credentials server will 
                                  validates it. 
                                  If client doesn't send credentials then server will not 
                                  authenticate, but allows client to establish the connection. 
                                  This behavior adheres to MQTT 3.1 specification.
                        REQUIRED: Clients should always provide credentials when connecting. 
                                  If client doesn't send credentials or they are invalid 
                                  server rejects the connection.
                   -->
                   <authentication>OPTIONAL</authentication>
                  
                   <!--Class name of the authenticator to use. class should 
                       inherit from org.dna.mqtt.moquette.server.IAuthenticator
                       Note: default implementation authenticates against carbon user store
                       based on supplied username/password
                   --> 
                   <authenticator>org.wso2.carbon.andes.authentication.andes.CarbonBasedMQTTAuthenticator</authenticator>
            </security>

        </mqtt>

    </transports>

    <!-- Depending on the database type selected in master-datasources.xml, you must enable the
    relevant Data access classes here. Currently supported stores are RDBMS(any RDBMS store) and
    Cassandra(CQL, Hector). These stores are accessed for two purposes.
    1. For message persistence ("messageStore")
    2. To persist and access other information relevant to messaging protocols.("contextStore").-->

    <!-- By default WSO2 MB runs with H2 persistent store. If you plan to use a different
    store, point to the relevant dataSource or uncomment the database appropriately.

    RDBMS
    =====
    If you are running an RDBMS you can use the existing RDBMS implementation of stores
    by pointing to the correct data source by updating the property "dataSource".

    Data source entry should be present in
    <MB_HOME>/repository/conf/datasources/master-datasources.xml.

    Cassandra
    =========
    For Cassandra depending on the driver (CQL or Hector) you use to connect to data store
    uncomment the relevant entry and COMMENT out the RDBMS entry.

    Update the <MB_HOME>/repository/conf/datasources/master-datasources.xml with Cassandra
    data source and update "dataSource" property for stores here.
    -->
    <persistence>

        <!-- RDBMS MB Store Configuration -->


        <messageStore class="org.wso2.andes.store.rdbms.RDBMSMessageStoreImpl">
            <property name="dataSource">jdbc/MySQLMessageStore</property>
        </messageStore>

        <contextStore class="org.wso2.andes.store.rdbms.RDBMSAndesContextStoreImpl">
            <property name="dataSource">jdbc/MySQLMessageStore</property>
        </contextStore>


        <!-- H2 Based In-Memory Store Configuration -->
<!--
        <messageStore class="org.wso2.andes.store.rdbms.h2.H2MemMessageStoreImpl">
        </messageStore>

        <contextStore class="org.wso2.andes.store.rdbms.h2.H2MemAndesContextStoreImpl">
        </contextStore>

-->

        <!-- External Cassandra Store Configuration -->

        <!-- NOTE: Update the master-datasources.xml file to connect to Cassandra data source
             READ the documentation to set advanced Cassandra tuning parameters.

            Advanced Tuning Parameters.

            gcGraceSeconds:
            Specifies the time to wait before garbage collecting tombstones (deletion markers).
            Defaults to 864000, or 10 days, which allows a great deal of time for consistency
            to be achieved prior to deletion. In many deployments this interval can be reduced,
            and in a single-node cluster it can be safely set to zero

            Replication strategy class:
            Strategy to determine the physical location of nodes to replication and their proximity
            to each other

            Replication factor:
            replication is the process of storing copies of data on multiple nodes to ensure
            reliability and fault tolerance. This value specify how many copies of same data should
            persisted.

            Read consistency level:
            Specifies how many replicas must respond to a read request before returning data
            Valid values are 'ONE','ALL','EACH_QUORUM','QUORUM','ONE','TWO','THREE','ANY'

            Write consistency level:
            Determines the number of replicas on which the write must succeed before returning an
            acknowledgement Valid values are
            'ONE','ALL','EACH_QUORUM','QUORUM','ONE','TWO','THREE','ANY' -->

        <!--CQL Based MB stores-->
<!--
        <messageStore class="org.wso2.andes.store.cassandra.CQLBasedMessageStoreImpl">
            <property name="dataSource">WSO2MBStoreDB</property>
            <property name="keyspace">MB_KEYSPACE</property>
            <property name="gcGraceSeconds">864000</property>
            <property name="strategyClass">org.apache.cassandra.locator.SimpleStrategy</property>
            <property name="replicationFactor">1</property>
            <property name="readConsistencyLevel">ONE</property>
            <property name="writeConsistencyLevel">ONE</property>
        </messageStore>

        <contextStore class="org.wso2.andes.store.cassandra.CQLBasedAndesContextStoreImpl">
            <property name="dataSource">WSO2MBStoreDB</property>
            <property name="keyspace">MB_KEYSPACE</property>
            <property name="strategyClass">org.apache.cassandra.locator.SimpleStrategy</property>
            <property name="replicationFactor">1</property>
            <property name="readConsistencyLevel">ONE</property>
            <property name="writeConsistencyLevel">ONE</property>
        </contextStore>
-->

        <!--Hector based MB stores-->
<!--
        <messageStore class="org.wso2.andes.store.cassandra.HectorBasedMessageStoreImpl">
            <property name="dataSource">WSO2MBStoreDB</property>
            <property name="keyspace">MB_KEYSPACE</property>
            <property name="gcGraceSeconds">864000</property>
            <property name="strategyClass">org.apache.cassandra.locator.SimpleStrategy</property>
            <property name="replicationFactor">1</property>
            <property name="readConsistencyLevel">ONE</property>
            <property name="writeConsistencyLevel">ONE</property>
        </messageStore>

        <contextStore class="org.wso2.andes.store.cassandra.HectorBasedAndesContextStoreImpl">
            <property name="dataSource">WSO2MBStoreDB</property>
            <property name="keyspace">MB_KEYSPACE</property>
            <property name="gcGraceSeconds">864000</property>
            <property name="strategyClass">org.apache.cassandra.locator.SimpleStrategy</property>
            <property name="replicationFactor">1</property>
            <property name="readConsistencyLevel">ONE</property>
            <property name="writeConsistencyLevel">ONE</property>
        </contextStore>
-->

        <!-- This class decides how unique IDs are generated for the MB node. This id generator is
        expected to be thread safe and a implementation of interface
        org.wso2.andes.server.cluster.coordination.MessageIdGenerator

        NOTE: This is NOT used in MB to generate message IDs. -->
        <idGenerator>org.wso2.andes.server.cluster.coordination.TimeStampBasedMessageIdGenerator</idGenerator>
    </persistence>

    <!-- Alter the flow that is triggered during a node fail -->
    <failoverBehaviour>

    </failoverBehaviour>

    <!-- This section allows you to tweak memory and processor allocations used by WSO2 MB.
    Broken down by critical processes so you have a clear view of which parameters to change in
    different scenarios.  -->
    <performanceTuning>

        <slots>
            <!--maximum time interval where slot can be retain in memory before updating to the
            cluster, in milliseconds -->
            <slotRetainTimeInMemory>1000</slotRetainTimeInMemory>

            <!--rough estimate for size of a slot-->
            <windowSize>1000</windowSize>

            <!--Number of SlotDeliveryWorker threads that should be started-->
            <workerThreadCount>5</workerThreadCount>
        </slots>

        <delivery>
            <!-- Maximum number of undelivered messages that can have in memory. Increasing this
            value increase the possibility of out of memory scenario but performance will be
            improved -->
            <maxNumberOfReadButUndeliveredMessages>1000</maxNumberOfReadButUndeliveredMessages>

            <!-- This is the ring buffer size of the delivery disruptor. This value should be a
            power of 2 (E.g. 1024, 2048, 4096). Use a small ring size if you want to reduce the
            memory usage. -->
            <ringBufferSize>4096</ringBufferSize>

            <!--Number of parallel readers used to used to read content from message store.
            Increasing this value will speed-up the message sending mechanism. But the load
            on the data store will increase. -->
            <parallelContentReaders>5</parallelContentReaders>

            <!-- Number of parallel delivery handlers used to send messages to subscribers.
            Increasing this value will speed-up the message sending mechanism. But the system load
            will increase. -->
            <parallelDeliveryHandlers>5</parallelDeliveryHandlers>

            <!-- The size of the batch represents, at a given time the number of messages that could 
            be retrived from the database. -->
            <contentReadBatchSize>65000</contentReadBatchSize>
        </delivery>

        <ackHandling>
            <!--Number of message acknowledgement handlers to process acknowledgements concurrently.
            These acknowledgement handlers will batch and process acknowledgements.  -->
            <ackHandlerCount>1</ackHandlerCount>

            <!--Maximum batch size of the acknowledgement handler. Andes process acknowledgements in
            batches using Disruptor Increasing the batch size reduces the number of calls made to
            database by MB. Depending on the database optimal batch size this value should be set.
            Batches will be of the maximum batch size mostly in high throughput scenarios.
            Underlying implementation use Disruptor for batching hence will batch message at a
            lesser value than this in low throughput scenarios -->
            <ackHandlerBatchSize>100</ackHandlerBatchSize>

            <!-- Message delivery from server to the client will be paused temporarily if number of
            delivered but unacknowledged message count reaches this size. Should be set considering
            message consume rate. This is to avoid overwhelming slow subscribers. -->
            <maxUnackedMessages>1000</maxUnackedMessages>
        </ackHandling>

        <inboundEvents>
            <!--Number of parallel writers used to write content to message store. Increasing this
            value will speed-up the message receiving mechanism. But the load on the data store will
            increase.-->
            <parallelMessageWriters>1</parallelMessageWriters>

            <!--Size of the Disruptor ring buffer for inbound event handling. For publishing at
            higher rates increasing the buffer size may give some advantage on keeping messages in
            memory and write.

            NOTE: Buffer size should be a value of power of two -->
            <bufferSize>65536</bufferSize>

            <!--Maximum batch size of the batch write operation for inbound messages. MB internals
            use Disruptor to batch events. Hence this batch size is set to avoid database requests
            with high load (with big batch sizes) to write messages. This need to be configured in
            high throughput messaging scenarios to regulate the hit on database from MB -->
            <messageWriterBatchSize>70</messageWriterBatchSize>
        </inboundEvents>

        <failover>
            <!-- Virtual host sync interval seconds in for the Virtual host syncing Task which will
            sync the Virtual host details across the cluster -->
            <vHostSyncTaskInterval>3600</vHostSyncTaskInterval>
        </failover>

        <messageExpiration>
            <checkInterval>10000</checkInterval>
            <messageBatchSize>1000</messageBatchSize>
        </messageExpiration>

        <messageCounter>
            <!-- Message counter tasks delay between the termination of one execution and the
            commencement of the next in seconds -->
            <counterTaskInterval>5</counterTaskInterval>

            <!-- Message count is updated in batches. Once the count exceed the batch size message
            count update is moved to message count update task. -->
            <countUpdateBatchSize>100</countUpdateBatchSize>
        </messageCounter>

        <!-- Code specific parameters to ensure messages get deleted as fast as possible without
        disturbing other processes.-->
        <messageDeletion>
            <!-- This is the Task interval (SECONDS) for the content removal task which will remove
            the actual message content from the store in the background. If the message rate is very
            high, users can set this to a lower value to minimise the delete requests per task. -->
            <contentRemovalTaskInterval>3</contentRemovalTaskInterval>
        </messageDeletion>

        <!--
            SIMPLE - Default Selector Mechanism
	        BITMAPS - BitMaps
            When using the subscriptions and topics in large quantity, BitMaps are faster than
            the existing ones
         -->
        <topicMatching>SIMPLE</topicMatching>

    </performanceTuning>

    <!-- This section is about how you want to view messaging statistics from the admin console and
    how you plan to interact with it. -->
    <managementConsole>
        <!--Maximum number of messages to be fetched using Andes message browser when browsing
        queues -->
        <messageBatchSizeForBrowserSubscriptions>200</messageBatchSizeForBrowserSubscriptions>

        <!-- This property defines the maximum message content length that can be displayed at the
        management console when browsing queues. If the message length exceeds the value, a
        truncated content will be displayed with a statement "message content too large to display."
        at the end. default value is 100000 (can roughly display a 100KB message.)
        * NOTE : Increasing this value could cause delays when loading the message content page.-->
        <maximumMessageDisplayLength>100000</maximumMessageDisplayLength>

    </managementConsole>

    <!-- Memory and resource exhaustion is something we should prevent and recover from.
    This section allows you to specify the threshold at which to reduce/stop frequently intensive
    operations within MB temporarily. -->
    <flowControl>
        <!-- This is the global buffer limits which enable/disable the flow control globally -->
        <global>
            <lowLimit>800</lowLimit>
            <highLimit>8000</highLimit>
        </global>

        <!-- This is the channel specific buffer limits which enable/disable the flow control
        locally -->
        <bufferBased>
            <lowLimit>100</lowLimit>
            <highLimit>1000</highLimit>
        </bufferBased>

        <memoryBased>
            <memoryCheckInterval>20000</memoryCheckInterval>
            <globalMemoryThresholdRatio>1.0</globalMemoryThresholdRatio>
            <globalMemoryRecoveryThresholdRatio>1.0</globalMemoryRecoveryThresholdRatio>
        </memoryBased>
        <connectionBased>
            <perConnectionMessageThreshold>1000</perConnectionMessageThreshold>
        </connectionBased>
    </flowControl>
</broker>
<datasources-configuration>

    <providers>
        <provider>org.wso2.carbon.ndatasource.rdbms.RDBMSDataSourceReader</provider>

        <!-- uncomment either one of the following entry when use external cassandra depending on data source (CQL or Hector) -->
        <!--<provider>org.wso2.carbon.cassandra.datareader.cql.CassandraDataSourceReader</provider>-->
        <!--<provider>org.wso2.carbon.cassandra.datareader.hector.HectorBasedDataSourceReader</provider>-->
    </providers>

    <datasources>

        <!-- For an explanation of the properties, see: http://people.apache.org/~fhanik/jdbc-pool/jdbc-pool.html -->
        <!--datasource>
            <name>SAMPLE_DATA_SOURCE</name>
            <jndiConfig>
                <name></name>
                <environment>
                    <property name="java.naming.factory.initial"></property>
                    <property name="java.naming.provider.url"></property>
                </environment>
            </jndiConfig>
            <definition type="RDBMS">
                <configuration>
                    <defaultAutoCommit></defaultAutoCommit>
                    <defaultReadOnly></defaultReadOnly>
                    <defaultTransactionIsolation>NONE|READ_COMMITTED|READ_UNCOMMITTED|REPEATABLE_READ|SERIALIZABLE</defaultTransactionIsolation>
                    <defaultCatalog></defaultCatalog>
                    <username></username>
                    <password svns:secretAlias="WSO2.DB.Password"></password>
                    <maxActive></maxActive>
                    <maxIdle></maxIdle>
                    <initialSize></initialSize>
                    <maxWait></maxWait>

                    <dataSourceClassName>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource</dataSourceClassName>
                    <dataSourceProps>
                        <property name="url">jdbc:mysql://localhost:3306/Test1</property>
                        <property name="user">root</property>
                        <property name="password">123</property>
                    </dataSourceProps>

                </configuration>
            </definition>
        </datasource-->

        <datasource>
            <name>WSO2_CARBON_DB</name>
            <description>The datasource used for registry and user manager</description>
            <jndiConfig>
                <name>jdbc/WSO2CarbonDB</name>
            </jndiConfig>
            <definition type="RDBMS">
                <configuration>
                    <url>jdbc:h2:repository/database/WSO2CARBON_DB;DB_CLOSE_ON_EXIT=FALSE;LOCK_TIMEOUT=60000</url>
                    <username>wso2carbon</username>
                    <password>wso2carbon</password>
                    <driverClassName>org.h2.Driver</driverClassName>
                    <maxActive>50</maxActive>
                    <maxWait>60000</maxWait>
                    <testOnBorrow>true</testOnBorrow>
                    <validationQuery>SELECT 1</validationQuery>
                    <validationInterval>30000</validationInterval>
                </configuration>
            </definition>
        </datasource>

        <!-- WSO2 MB embedded H2 Store     -->
<!--        <datasource>
            <name>WSO2_MB_STORE_DB</name>
            <description>The datasource used for message broker database</description>
            <jndiConfig>
                <name>WSO2MBStoreDB</name>
            </jndiConfig>
            <definition type="RDBMS">
                <configuration>
                    <url>jdbc:h2:repository/database/WSO2MB_DB;DB_CLOSE_ON_EXIT=FALSE;LOCK_TIMEOUT=60000</url>
                    <driverClassName>org.h2.Driver</driverClassName>
                    <maxActive>50</maxActive>
                    <maxWait>60000</maxWait>
                    <testOnBorrow>true</testOnBorrow>
                    <validationQuery>SELECT 1</validationQuery>
                    <validationInterval>30000</validationInterval>
                </configuration>
            </definition>
        </datasource>-->

        <!-- WSO2 MB in memory store     -->

        <datasource>
            <name>WSO2_MB_IN_MEMORY_STORE_DB</name>
            <jndiConfig>
                <name>WSO2MBInMemoryStoreDB</name>
            </jndiConfig>
            <definition type="RDBMS">
                <configuration>
                    <url>jdbc:h2:mem:msg_store;DB_CLOSE_DELAY=-1</url>
                    <driverClassName>org.h2.Driver</driverClassName>
                </configuration>
            </definition>
        </datasource>


        <!-- external Cassandra data source. please enable either one of datasource (CQL or Hector) based on your preference -->
        <!-- CQL datasource -->
<!--
        <datasource>
            <name>WSO2_CASSANDRA_DB</name>
            <description>The datasource used for cassandra</description>
            <jndiConfig>
                <name>WSO2MBStoreDB</name>
            </jndiConfig>
            <definition type="CASSANDRA">
                <configuration>
                    <async>false</async>
                    <clusterName>TestCluster</clusterName>
                    <compression>SNAPPY</compression>
                    <concurrency>100</concurrency>
                    <username>admin</username>
                    <password encrypted="true">admin</password>
                    <port>9042</port>
                    <maxConnections>100</maxConnections>

                    <hosts>
                        <host>localhost</host>
                    </hosts>
                    <loadBalancePolicy>
                        <exclusionThreshold>2.5</exclusionThreshold>
                        <latencyAware>true</latencyAware>
                        <minMeasure>100</minMeasure>
                        <policyName>RoundRobinPolicy</policyName>
                        <retryPeriod>10</retryPeriod>
                        <scale>2</scale>
                    </loadBalancePolicy>

                    <poolOptions>
                        <coreConnectionsForLocal>7</coreConnectionsForLocal>
                        <coreConnectionsForRemote>1</coreConnectionsForRemote>
                        <maxConnectionsForLocal>10</maxConnectionsForLocal>
                        <maxConnectionsForRemote>10</maxConnectionsForRemote>
                        <maxSimultaneousRequestsForLocal>10</maxSimultaneousRequestsForLocal>
                        <maxSimultaneousRequestsForRemote>10</maxSimultaneousRequestsForRemote>
                        <minSimultaneousRequestsForLocal>10</minSimultaneousRequestsForLocal>
                        <minSimultaneousRequestsForRemote>10</minSimultaneousRequestsForRemote>
                    </poolOptions>

                    <reconnectPolicy>
                        <baseDelayMs>100</baseDelayMs>
                        <policyName>ConstantReconnectionPolicy</policyName>
                    </reconnectPolicy>
                    <socketOptions>
                        <connectTimeoutMillis>10000</connectTimeoutMillis>
                        <keepAlive>true</keepAlive>
                        <readTimeoutMillis>15000</readTimeoutMillis>
                        <tcpNoDelay>true</tcpNoDelay>
                    </socketOptions>
                </configuration>

            </definition>
        </datasource>
-->


        <!-- Hector datasource -->
<!--
        <datasource>
            <name>HectorDS</name>
            <description>The datasource used for RSS metadata repository</description>
            <jndiConfig>
                <name>WSO2MBStoreDB</name>
            </jndiConfig>
            <definition type="HECTOR">
                <configuration>
                    <hosts>localhost:9160</hosts>
                    <username>admin</username>
                    <password>admin</password>
                    <clusterName>TestCluster</clusterName>
                    <maxActive>200</maxActive>
                    <enableSecurity>false</enableSecurity>
                </configuration>
            </definition>
        </datasource>
-->
        <!-- end of external Cassandra data sources.  -->

        <!-- MySQL data source -->

       <datasource>
             <name>MYSQL_DATA_SOURCE</name>
             <jndiConfig>
                 <name>jdbc/MySQLMessageStore</name>
             </jndiConfig>
             <definition type="RDBMS">
                 <configuration>
                     <driverClassName>com.mysql.jdbc.Driver</driverClassName>
                     <url>jdbc:mysql://10.100.4.40/WSO2_MB</url>
                     <username>root</username>
                     <password>root</password>
                 </configuration>
             </definition>
         </datasource>


        <!-- MSSQL server -->
        <!-- Please enable any one of the following datasource based on your MSSQL driver library -->
        <!-- JTDS datasource -->
<!--
        <datasource>
            <name>WSO2_MB_STORE_DB</name>
            <jndiConfig>
                <name>WSO2MBStoreDB</name>
            </jndiConfig>
            <definition type="RDBMS">
            <configuration>
                    <url>jdbc:jtds:sqlserver://localhost:1433/wso2_mb</url>
                    <username>sa</username>
                    <password>sa</password>
                    <driverClassName>net.sourceforge.jtds.jdbc.Driver</driverClassName>
                    <maxActive>200</maxActive>
                    <maxWait>60000</maxWait>
                    <minIdle>5</minIdle>
                    <testOnBorrow>true</testOnBorrow>
                    <validationQuery>SELECT 1</validationQuery>
                    <validationInterval>30000</validationInterval>
                </configuration>
            </definition>
        </datasource>
-->

        <!-- SQLServerXA datasource -->
<!--
        <datasource>
            <name>WSO2_MB_STORE_DB</name>
            <jndiConfig>
                <name>WSO2MBStoreDB</name>
            </jndiConfig>
            <definition type="RDBMS">
                <configuration>
                    <dataSourceClassName>com.microsoft.sqlserver.jdbc.SQLServerXADataSource</dataSourceClassName>
                    <dataSourceProps>
                <property name = "URL">jdbc:sqlserver://localhost\SQLExpress:1433</property>
                <property name="databaseName">wso2_mb</property>
                        <property name="user">sa</property>
                        <property name="password">sa</property>
                    </dataSourceProps>
                </configuration>
            </definition>
        </datasource>
-->

<!--
        <datasource>
            <name>ORACLE_DATA_SOURCE</name>
            <jndiConfig>
                <name>WSO2MBStoreDB</name>
            </jndiConfig>
            <definition type="RDBMS">
                <configuration>
                    <driverClassName>oracle.jdbc.driver.OracleDriver</driverClassName>
                    <url>jdbc:oracle:thin:@localhost:1521/orcl</url>
                    <maxActive>100</maxActive>
                    <maxWait>60000</maxWait>
                    <minIdle>5</minIdle>
                    <testOnBorrow>true</testOnBorrow>
                    <validationQuery>SELECT 1 FROM DUAL</validationQuery>
                    <validationInterval>30000</validationInterval>
                    <username>scott</username>
                    <password>tiger</password>
                </configuration>
            </definition>
        </datasource>
-->

    </datasources>
</datasources-configuration>
<!--
  ~ Copyright 2005-2011 WSO2, Inc. (http://wso2.com)
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~ http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  -->

<axisconfig name="AxisJava2.0">

    <!-- ================================================= -->
    <!-- Globally engaged modules -->
    <!-- ================================================= -->
    <module ref="addressing"/>

    <!-- ================================================= -->
    <!-- Parameters -->
    <!-- ================================================= -->
    <parameter name="hotdeployment">${hotdeployment}</parameter>
    <parameter name="hotupdate">${hotupdate}</parameter>
    <parameter name="enableMTOM" locked="false">optional</parameter>
    <parameter name="cacheAttachments">true</parameter>
    <parameter name="attachmentDIR">work/mtom</parameter>
    <parameter name="sizeThreshold">4000</parameter>

    <parameter name="EnableChildFirstClassLoading">${childfirstCL}</parameter>

    <!--
    The exposeServiceMetadata parameter decides whether the metadata (WSDL, schema, policy) of
    the services deployed on Axis2 should be visible when ?wsdl, ?wsdl2, ?xsd, ?policy requests
    are received.
    This parameter can be defined in the axi2.xml file, in which case this will be applicable
    globally, or in the services.xml files, in which case, it will be applicable to the
    Service groups and/or services, depending on the level at which the parameter is declared.
    This value of this parameter defaults to true.
    -->
    <parameter name="exposeServiceMetadata">true</parameter>

    <!--If turned on with use the Accept header of the request to determine the contentType of the
    response-->
    <parameter name="httpContentNegotiation">true</parameter>

    <!--
    Defines how the persistence of WS-ReliableMessaging is handled

    Possible value are: inmemory & persistent
    -->
    <!-- Following parameter will completely disable REST handling in both the servlets-->
    <parameter name="disableREST" locked="false">false</parameter>

    <parameter name="Sandesha2StorageManager">inmemory</parameter>

    <!-- This deployment interceptor will be called whenever before a module is initialized or
     service is deployed -->
    <listener class="org.wso2.carbon.core.deployment.DeploymentInterceptor"/>

    <!-- setting servicePath. contextRoot is defined in the carbon.xml file -->
    <!-- modification of this variable should be accompanied by the change in 'ServerURL' in carbon.xml file -->
    <parameter name="servicePath">services</parameter>

    <!--the directory in which .aar services are deployed inside axis2 repository-->
    <parameter name="ServicesDirectory">axis2services</parameter>

    <!--the directory in which modules are deployed inside axis2 repository-->
    <parameter name="ModulesDirectory">axis2modules</parameter>

    <parameter name="userAgent" locked="true">
        WSO2 Message Broker-2.5.0
    </parameter>
    <parameter name="server" locked="true">
        WSO2 Message Broker-2.5.0
    </parameter>

    <!-- ========================================================================-->

    <!--During a fault, stacktrace can be sent with the fault message. The following flag will control -->
    <!--that behaviour.-->
    <parameter name="sendStacktraceDetailsWithFaults">false</parameter>

    <!--If there aren't any information available to find out the fault reason, we set the message of the expcetion-->
    <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be -->
    <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag-->
    <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.-->
    <parameter name="DrillDownToRootCauseForFaultReason">false</parameter>

    <!--Set the flag to true if you want to enable transport level session mangment-->
    <parameter name="manageTransportSession">true</parameter>

    <!-- Synapse Configuration file -->
    <parameter name="SynapseConfig.ConfigurationFile" locked="false">
        ./repository/deployment/server/synapse-configs
    </parameter>

    <!-- Synapse Home parameter -->
    <parameter name="SynapseConfig.HomeDirectory" locked="false">.</parameter>

    <!-- Resolve root used to resolve synapse references like schemas inside a WSDL -->
    <parameter name="SynapseConfig.ResolveRoot" locked="false">.</parameter>

    <!-- Synapse Server name parameter -->
    <parameter name="SynapseConfig.ServerName" locked="false">WSO2 Carbon Server</parameter>

    <!--By default, JAXWS services are created by reading annotations. WSDL and schema are generated-->
    <!--using a separate WSDL generator only when ?wsdl is called. Therefore, even if you engage-->
    <!--policies etc.. to AxisService, it doesn't appear in the WSDL. By setting the following property-->
    <!--to true, you can create the AxisService using the generated WSDL and remove the need for a-->
    <!--WSDL generator. When ?wsdl is called, WSDL is generated in the normal way.-->
    <parameter name="useGeneratedWSDLinJAXWS">${jaxwsparam}</parameter>

    <!-- Deployer for the dataservice. -->
    <!--<deployer extension="dbs" directory="dataservices" class="org.wso2.dataservices.DBDeployer"/>-->

    <!-- Axis1 deployer for Axis2-->
    <!--<deployer extension="wsdd" class="org.wso2.carbon.axis1services.Axis1Deployer" directory="axis1services"/>-->

    <!-- POJO service deployer for Jar -->
    <!--<deployer extension="jar" class="org.apache.axis2.deployment.POJODeployer" directory="pojoservices"/>-->

    <!-- POJO service deployer for Class  -->
    <!--<deployer extension="class" class="org.apache.axis2.deployment.POJODeployer" directory="pojoservices"/>-->

    <!-- JAXWS service deployer  -->
    <!--<deployer extension=".jar" class="org.apache.axis2.jaxws.framework.JAXWSDeployer" directory="servicejars"/>-->
    <!-- ================================================= -->
    <!-- Message Receivers -->
    <!-- ================================================= -->
    <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for -->
    <!--all the other MEP implement it and add the correct entry to here , so that you can refer from-->
    <!--any operation -->
    <!--Note : You can ovride this for particular service by adding the same element with your requirement-->

    <messageReceivers>
        <messageReceiver mep="http://www.w3.org/ns/wsdl/in-only";
                         class="org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver"/>
        <messageReceiver mep="http://www.w3.org/ns/wsdl/robust-in-only";
                         class="org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver"/>
        <messageReceiver mep="http://www.w3.org/ns/wsdl/in-out";
                         class="org.apache.axis2.rpc.receivers.RPCMessageReceiver"/>
    </messageReceivers>

    <messageFormatters>
        <messageFormatter contentType="application/x-www-form-urlencoded"
                          class="org.apache.axis2.transport.http.XFormURLEncodedFormatter"/>
        <messageFormatter contentType="multipart/form-data"
                          class="org.apache.axis2.transport.http.MultipartFormDataFormatter"/>
        <messageFormatter contentType="application/xml"
                          class="org.apache.axis2.transport.http.ApplicationXMLFormatter"/>
        <messageFormatter contentType="text/xml"
                          class="org.apache.axis2.transport.http.SOAPMessageFormatter"/>
        <messageFormatter contentType="application/soap+xml"
                          class="org.apache.axis2.transport.http.SOAPMessageFormatter"/>

        <!--JSON Message Formatters-->
        <!--messageFormatter contentType="application/json"
                          class="org.apache.axis2.json.JSONMessageFormatter"/-->
        <messageFormatter contentType="application/json"
                                  class="org.apache.axis2.json.gson.JsonFormatter" />
        <messageFormatter contentType="application/json/badgerfish"
                          class="org.apache.axis2.json.JSONBadgerfishMessageFormatter"/>
        <!--messageFormatter contentType="text/javascript"
                          class="org.apache.axis2.json.JSONMessageFormatter"/-->
        <messageFormatter contentType="text/javascript"
                                  class="org.apache.axis2.json.gson.JsonFormatter" />

        <!--messageFormatter contentType="application/x-www-form-urlencoded"
                        class="org.wso2.carbon.relay.ExpandingMessageFormatter"/-->
        <!--messageFormatter contentType="multipart/form-data"
                        class="org.wso2.carbon.relay.ExpandingMessageFormatter"/-->
        <!--messageFormatter contentType="application/xml"
                        class="org.wso2.carbon.relay.ExpandingMessageFormatter"/-->
        <!--messageFormatter contentType="text/html"
                        class="org.wso2.carbon.relay.ExpandingMessageFormatter"/-->
        <!--messageFormatter contentType="application/soap+xml"
                        class="org.wso2.carbon.relay.ExpandingMessageFormatter"/-->
        <!--messageFormatter contentType="x-application/hessian"
			class="org.apache.synapse.format.hessian.HessianMessageFormatter"/-->
        <!--<messageFormatter contentType="">
			class="org.apache.synapse.format.hessian.HessianMessageFormatter"/-->
    </messageFormatters>

    <messageBuilders>
        <messageBuilder contentType="application/xml"
                        class="org.apache.axis2.builder.ApplicationXMLBuilder"/>
        <messageBuilder contentType="application/x-www-form-urlencoded"
                        class="org.apache.axis2.builder.XFormURLEncodedBuilder"/>
        <messageBuilder contentType="multipart/form-data"
                        class="org.apache.axis2.builder.MultipartFormDataBuilder"/>

        <!--JSON Message Builders-->
        <!--messageBuilder contentType="application/json"
                        class="org.apache.axis2.json.JSONOMBuilder"/-->
        <messageBuilder contentType="application/json"
                                class="org.apache.axis2.json.gson.JsonBuilder" />
        <messageBuilder contentType="application/json/badgerfish"
                        class="org.apache.axis2.json.JSONBadgerfishOMBuilder"/>
        <!--messageBuilder contentType="text/javascript"
                        class="org.apache.axis2.json.JSONOMBuilder"/-->
        <messageBuilder contentType="text/javascript"
                                class="org.apache.axis2.json.gson.JsonBuilder" />

        <!--messageBuilder contentType="application/xml"
     		        class="org.wso2.carbon.relay.BinaryRelayBuilder"/-->
        <!--messageBuilder contentType="application/x-www-form-urlencoded"
                        class="org.wso2.carbon.relay.BinaryRelayBuilder"/-->
        <!--messageBuilder contentType="multipart/form-data"
                        class="org.wso2.carbon.relay.BinaryRelayBuilder"/-->
        <!--messageBuilder contentType="multipart/related"
                       class="org.wso2.carbon.relay.BinaryRelayBuilder"/-->
        <!--messageBuilder contentType="application/soap+xml"
                       class="org.wso2.carbon.relay.BinaryRelayBuilder"/-->
        <!--messageBuilder contentType="text/plain"
                       class="org.wso2.carbon.relay.BinaryRelayBuilder"/-->
        <!--messageBuilder contentType="text/xml"
                       class="org.wso2.carbon.relay.BinaryRelayBuilder"/-->
        <!--messageFormatter contentType="text/plain"
                        class="org.apache.axis2.format.PlainTextBuilder"/-->
        <!--messageBuilder contentType="x-application/hessian"
		       class="org.apache.synapse.format.hessian.HessianMessageBuilder"/-->
    </messageBuilders>


    <!-- ================================================= -->
    <!-- In Transports -->
    <!-- ================================================= -->
    <transportReceiver name="http"
                       class="org.wso2.carbon.core.transports.http.HttpTransportListener">
        <!--
           Uncomment the following if you are deploying this within an application server. You
           need to specify the HTTP port of the application server
        -->
        <parameter name="port">9763</parameter>

        <!--
       Uncomment the following to enable any proxy like Apache2 mod_proxy or any load balancer. The port on the proxy server like Apache is 80
       in this case.
        -->
        <!--<parameter name="proxyPort">80</parameter>-->
    </transportReceiver>

    <!--Please uncomment this in Multiple Instance Scenario if you want to use NIO Transport Recievers and 
 	Remove the current transport REceivers in axis2.xml -->
    <!--transportReceiver name="http" class="org.apache.synapse.transport.nhttp.HttpCoreNIOListener">
        <parameter name="port" locked="false">8280</parameter>
        <parameter name="non-blocking" locked="false">true</parameter>
    </transportReceiver>
    
    <transportReceiver name="https" class="org.apache.synapse.transport.nhttp.HttpCoreNIOSSLListener">
        <parameter name="port" locked="false">8243</parameter>
        <parameter name="non-blocking" locked="false">true</parameter>
        <parameter name="keystore" locked="false">
            <KeyStore>
                <Location>repository/resources/security/wso2carbon.jks</Location>
                <Type>JKS</Type>
                <Password>wso2carbon</Password>
                <KeyPassword>wso2carbon</KeyPassword>
            </KeyStore>
        </parameter>
        <parameter name="truststore" locked="false">
            <TrustStore>
                <Location>repository/resources/security/client-truststore.jks</Location>
                <Type>JKS</Type>
                <Password>wso2carbon</Password>
            </TrustStore>
        </parameter>
    </transportReceiver-->


    <transportReceiver name="https"
                       class="org.wso2.carbon.core.transports.http.HttpsTransportListener">
        <!--
           Uncomment the following if you are deploying this within an application server. You
           need to specify the HTTPS port of the application server
        -->
        <parameter name="port">9443</parameter>

        <!--
       Uncomment the following to enable any proxy like Apache2 mod_proxy or any load balancer. The port on a proxy server like Apache is 443
       in this case.
        -->
        <!--<parameter name="proxyPort">443</parameter>-->
    </transportReceiver>

    <!--
       Uncomment the following segment to enable TCP transport.
       Note : Addressing module should be engaged for TCP transport to work
    -->
    <!--<transportReceiver name="tcp"
                       class="org.apache.axis2.transport.tcp.TCPServer">
        <parameter name="port">6667</parameter>
    </transportReceiver>-->

    <!--
     To Enable Mail Transport Listener, please uncomment the following.
    -->
    <!--<transportReceiver name="mailto" class="org.apache.axis2.transport.mail.MailTransportListener">

    </transportReceiver>-->


    <!--
      Uncomment this and configure as appropriate for JMS transport support,
      after setting up your JMS environment (e.g. ActiveMQ)
    -->
    <!--<transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener">
        <parameter name="myTopicConnectionFactory">
        	<parameter name="java.naming.factory.initial">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
        	<parameter name="java.naming.provider.url">tcp://localhost:61616</parameter>
        	<parameter name="transport.jms.ConnectionFactoryJNDIName">TopicConnectionFactory</parameter>
        </parameter>

        <parameter name="myQueueConnectionFactory">
        	<parameter name="java.naming.factory.initial">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
        	<parameter name="java.naming.provider.url">tcp://localhost:61616</parameter>
        	<parameter name="transport.jms.ConnectionFactoryJNDIName">QueueConnectionFactory</parameter>
        </parameter>

        <parameter name="default">
        	<parameter name="java.naming.factory.initial">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter>
        	<parameter name="java.naming.provider.url">tcp://localhost:61616</parameter>
        	<parameter name="transport.jms.ConnectionFactoryJNDIName">QueueConnectionFactory</parameter>
        </parameter>
    </transportReceiver>-->

    <!--Uncomment this and configure as appropriate for JMS transport support with Apache Qpid -->
    <!--transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener">
        <parameter name="myTopicConnectionFactory" locked="false">
            <parameter name="java.naming.factory.initial" locked="false">org.apache.qpid.jndi.PropertiesFileInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" locked="false">repository/conf/jndi.properties</parameter>
            <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">TopicConnectionFactory</parameter>
            <parameter name="transport.jms.ConnectionFactoryType" locked="false">topic</parameter>
        </parameter>

        <parameter name="myQueueConnectionFactory" locked="false">
            <parameter name="java.naming.factory.initial" locked="false">org.apache.qpid.jndi.PropertiesFileInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" locked="false">repository/conf/jndi.properties</parameter>
            <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter>
            <parameter name="transport.jms.ConnectionFactoryType" locked="false">queue</parameter>
        </parameter>

        <parameter name="default" locked="false">
            <parameter name="java.naming.factory.initial" locked="false">org.apache.qpid.jndi.PropertiesFileInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" locked="false">repository/conf/jndi.properties</parameter>
            <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter>
            <parameter name="transport.jms.ConnectionFactoryType" locked="false">queue</parameter>
        </parameter>
    </transportReceiver-->

    <!--Uncomment this and configure as appropriate for JMS transport support with WSO2 MB 2.x.x -->
    <!--transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener">
        <parameter name="myTopicConnectionFactory" locked="false">
           <parameter name="java.naming.factory.initial" locked="false">org.wso2.andes.jndi.PropertiesFileInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" locked="false">repository/conf/jndi.properties</parameter>
            <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">TopicConnectionFactory</parameter>
            <parameter name="transport.jms.ConnectionFactoryType" locked="false">topic</parameter>
        </parameter>

        <parameter name="myQueueConnectionFactory" locked="false">
            <parameter name="java.naming.factory.initial" locked="false">org.wso2.andes.jndi.PropertiesFileInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" locked="false">repository/conf/jndi.properties</parameter>
            <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter>
           <parameter name="transport.jms.ConnectionFactoryType" locked="false">queue</parameter>
        </parameter>

        <parameter name="default" locked="false">
            <parameter name="java.naming.factory.initial" locked="false">org.wso2.andes.jndi.PropertiesFileInitialContextFactory</parameter>
            <parameter name="java.naming.provider.url" locked="false">repository/conf/jndi.properties</parameter>
            <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter>
            <parameter name="transport.jms.ConnectionFactoryType" locked="false">queue</parameter>
        </parameter>
    </transportReceiver-->


    <!-- ================================================= -->
    <!-- Out Transports -->
    <!-- ================================================= -->

    <!--transportSender name="tcp"
                     class="org.apache.axis2.transport.tcp.TCPTransportSender"/-->
    <transportReceiver name="local"
                       class="org.wso2.carbon.core.transports.local.CarbonLocalTransportReceiver"/>
    <transportSender name="local"
                     class="org.wso2.carbon.core.transports.local.CarbonLocalTransportSender"/>
    <!--<transportSender name="jms"
                     class="org.apache.axis2.transport.jms.JMSSender"/>-->
    <transportSender name="http"
                     class="org.apache.axis2.transport.http.CommonsHTTPTransportSender">
        <parameter name="PROTOCOL">HTTP/1.1</parameter>
        <parameter name="Transfer-Encoding">chunked</parameter>
        <!-- This parameter has been added to overcome problems encounted in SOAP action parameter -->
        <parameter name="OmitSOAP12Action">true</parameter>
    </transportSender>
    <transportSender name="https"
                     class="org.apache.axis2.transport.http.CommonsHTTPTransportSender">
        <parameter name="PROTOCOL">HTTP/1.1</parameter>
        <parameter name="Transfer-Encoding">chunked</parameter>
        <!-- This parameter has been added to overcome problems encounted in SOAP action parameter -->
        <parameter name="OmitSOAP12Action">true</parameter>
    </transportSender>

    <!-- To enable mail transport sender, ncomment the following and change the parameters
         accordingly-->
    <!--<transportSender name="mailto"
                     class="org.apache.axis2.transport.mail.MailTransportSender">
        <parameter name="mail.smtp.from">[email protected]</parameter>
        <parameter name="mail.smtp.user">wso2demomail</parameter>
        <parameter name="mail.smtp.password">mailpassword</parameter>
        <parameter name="mail.smtp.host">smtp.gmail.com</parameter>

        <parameter name="mail.smtp.port">587</parameter>
        <parameter name="mail.smtp.starttls.enable">true</parameter>
        <parameter name="mail.smtp.auth">true</parameter>
    </transportSender>-->

    <!--Please uncomment this in Multiple Instance Scenario if you want to use NIO sender -->
    <!--  
    <transportSender name="http" class="org.apache.synapse.transport.nhttp.HttpCoreNIOSender">
        <parameter name="non-blocking" locked="false">true</parameter>
    </transportSender>
    <transportSender name="https" class="org.apache.synapse.transport.nhttp.HttpCoreNIOSSLSender">
        <parameter name="non-blocking" locked="false">true</parameter>
        <parameter name="keystore" locked="false">
            <KeyStore>
                <Location>repository/resources/security/wso2carbon.jks</Location>
                <Type>JKS</Type>
                <Password>wso2carbon</Password>
                <KeyPassword>wso2carbon</KeyPassword>
            </KeyStore>
        </parameter>
        <parameter name="truststore" locked="false">
            <TrustStore>
                <Location>repository/resources/security/client-truststore.jks</Location>
                <Type>JKS</Type>
                <Password>wso2carbon</Password>
            </TrustStore>
        </parameter>
    </transportSender>
	-->


    <!-- ================================================= -->
    <!-- Phases  -->
    <!-- ================================================= -->
    <phaseOrder type="InFlow">
        <!--  System pre defined phases       -->
        <!--
           The MsgInObservation phase is used to observe messages as soon as they are
           received. In this phase, we could do some things such as SOAP message tracing & keeping
           track of the time at which a particular message was received

           NOTE: This should be the very first phase in this flow
        -->
        <phase name="MsgInObservation"/>

        <phase name="Validation"/>
        <phase name="Transport">
            <handler name="RequestURIBasedDispatcher"
                     class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher">
                <order phase="Transport"/>
            </handler>
            <handler name="SOAPActionBasedDispatcher"
                     class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher">
                <order phase="Transport"/>
            </handler>
            <handler name="RequestURIOperationDispatcher"
                     class="org.apache.axis2.dispatchers.RequestURIOperationDispatcher" />
            <handler name="JSONMessageHandler"
                     class="org.apache.axis2.json.gson.JSONMessageHandler" />
        </phase>
        <phase name="Addressing">
            <handler name="AddressingBasedDispatcher"
                     class="org.wso2.carbon.core.multitenancy.MultitenantAddressingBasedDispatcher">
                <order phase="Addressing"/>
            </handler>
        </phase>
        <phase name="Ghost">
            <handler name="GhostDispatcher"
                     class="org.wso2.carbon.core.dispatchers.GhostDispatcher"/>
        </phase>
        <phase name="Security"/>
        <phase name="PreDispatch"/>
        <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase">
            <handler name="RequestURIBasedDispatcher"
                     class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"/>
            <handler name="SOAPActionBasedDispatcher"
                     class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"/>
            <handler name="SOAPMessageBodyBasedDispatcher"
                     class="org.apache.axis2.dispatchers.SOAPMessageBodyBasedDispatcher"/>

            <handler name="HTTPLocationBasedDispatcher"
                     class="org.apache.axis2.dispatchers.HTTPLocationBasedDispatcher"/>
        </phase>
        <!--  System pre defined phases       -->
        <phase name="RMPhase"/>
        <phase name="OpPhase"/>
        <!--   After Postdispatch phase module author or or service author can add any phase he want      -->
        <phase name="OperationInPhase"/>
    </phaseOrder>
    <phaseOrder type="OutFlow">
        <!-- Handlers related to unified-endpoint component are added to the UEPPhase -->
        <phase name="UEPPhase"/>
        <phase name="RMPhase"/>
        <phase name="OpPhase"/>
        <!--      user can add his own phases to this area  -->
        <phase name="OperationOutPhase"/>
        <!--system predefined phase-->
        <!--these phase will run irrespective of the service-->
        <phase name="PolicyDetermination"/>
        <phase name="MessageOut"/>
        <phase name="Security"/>

        <!--
           The MsgOutObservation phase is used to observe messages just before the
           responses are sent out. In this phase, we could do some things such as SOAP message
           tracing & keeping track of the time at which a particular response was sent.

           NOTE: This should be the very last phase in this flow
        -->
        <phase name="MsgOutObservation"/>
        <!--Following phase is added to publish stats -->
        <phase name="StatReporting"/>
    </phaseOrder>
    <phaseOrder type="InFaultFlow">
        <!--  System pre defined phases       -->
        <!--
           The MsgInObservation phase is used to observe messages as soon as they are
           received. In this phase, we could do some things such as SOAP message tracing & keeping
           track of the time at which a particular message was received

           NOTE: This should be the very first phase in this flow
        -->
        <phase name="MsgInObservation"/>

        <phase name="Validation"/>
        <phase name="Transport">
            <handler name="RequestURIBasedDispatcher"
                     class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher">
                <order phase="Transport"/>
            </handler>
            <handler name="SOAPActionBasedDispatcher"
                     class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher">
                <order phase="Transport"/>
            </handler>
        </phase>

        <phase name="Addressing">
            <handler name="AddressingBasedDispatcher"
                     class="org.apache.axis2.dispatchers.AddressingBasedDispatcher">
                <order phase="Addressing"/>
            </handler>
        </phase>
        <phase name="Ghost">
            <handler name="GhostDispatcher"
                     class="org.wso2.carbon.core.dispatchers.GhostDispatcher"/>
        </phase>
        <phase name="Security"/>
        <phase name="PreDispatch"/>
        <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase">
            <handler name="RequestURIBasedDispatcher"
                     class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"/>
            <handler name="SOAPActionBasedDispatcher"
                     class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"/>
            <handler name="SOAPMessageBodyBasedDispatcher"
                     class="org.apache.axis2.dispatchers.SOAPMessageBodyBasedDispatcher"/>

            <handler name="HTTPLocationBasedDispatcher"
                     class="org.apache.axis2.dispatchers.HTTPLocationBasedDispatcher"/>
        </phase>
        <phase name="RMPhase"/>
        <phase name="OpPhase"/>
        <!--      user can add his own phases to this area  -->
        <phase name="OperationInFaultPhase"/>
    </phaseOrder>
    <phaseOrder type="OutFaultFlow">
        <!-- Handlers related to unified-endpoint component are added to the UEPPhase -->
        <phase name="UEPPhase"/>
        <phase name="RMPhase"/>
        <!--      user can add his own phases to this area  -->
        <phase name="OperationOutFaultPhase"/>
        <phase name="PolicyDetermination"/>
        <phase name="MessageOut"/>
        <phase name="Security"/>
	<phase name="Transport"/>
        <!--
           The MsgOutObservation phase is used to observe messages just before the
           responses are sent out. In this phase, we could do some things such as SOAP message
           tracing & keeping track of the time at which a particular response was sent.

           NOTE: This should be the very last phase in this flow
        -->
        <phase name="MsgOutObservation"/>
        <!--Following phase is added to publish stats -->
        <phase name="StatReporting"/>
    </phaseOrder>

    <clustering class="org.wso2.carbon.core.clustering.hazelcast.HazelcastClusteringAgent"
                enable="true">

        <!--
           This parameter indicates whether the cluster has to be automatically initalized
           when the AxisConfiguration is built. If set to "true" the initialization will not be
           done at that stage, and some other party will have to explictly initialize the cluster.
        -->
        <parameter name="AvoidInitiation">true</parameter>

        <!--
           The membership scheme used in this setup. The only values supported at the moment are
           "multicast" and "wka"

           1. multicast - membership is automatically discovered using multicasting
           2. wka - Well-Known Address based multicasting. Membership is discovered with the help
                    of one or more nodes running at a Well-Known Address. New members joining a
                    cluster will first connect to a well-known node, register with the well-known node
                    and get the membership list from it. When new members join, one of the well-known
                    nodes will notify the others in the group. When a member leaves the cluster or
                    is deemed to have left the cluster, it will be detected by the Group Membership
                    Service (GMS) using a TCP ping mechanism.
        -->
        <parameter name="membershipScheme">wka</parameter>
        <!--<parameter name="licenseKey">xxx</parameter>-->
        <!--<parameter name="mgtCenterURL">http://localhost:8081/mancenter/</parameter>-->

        <!--
         The clustering domain/group. Nodes in the same group will belong to the same multicast
         domain. There will not be interference between nodes in different groups.
        -->
        <parameter name="domain">wso2.carbon.domain</parameter>

        <!-- The multicast address to be used -->
        <!--<parameter name="mcastAddress">228.0.0.4</parameter>-->

        <!-- The multicast port to be used -->
        <parameter name="mcastPort">45564</parameter>

        <parameter name="mcastTTL">100</parameter>

        <parameter name="mcastTimeout">60</parameter>

        <!--
           The IP address of the network interface to which the multicasting has to be bound to.
           Multicasting would be done using this interface.
        -->
        <!--
            <parameter name="mcastBindAddress">127.0.0.1</parameter>
        -->
        <!-- The host name or IP address of this member -->

        <parameter name="localMemberHost">10.100.4.40</parameter>

        <!--
            The bind adress of this member. The difference between localMemberHost & localMemberBindAddress
            is that localMemberHost is the one that is advertised by this member, while localMemberBindAddress
            is the address to which this member is bound to.
        -->
        <!--
        <parameter name="localMemberBindAddress">127.0.0.1</parameter>
        -->

        <!--
        The TCP port used by this member. This is the port through which other nodes will
        contact this member
         -->
        <parameter name="localMemberPort">4000</parameter>

        <!--
            The bind port of this member. The difference between localMemberPort & localMemberBindPort
            is that localMemberPort is the one that is advertised by this member, while localMemberBindPort
            is the port to which this member is bound to.
        -->
        <!--
        <parameter name="localMemberBindPort">4001</parameter>
        -->

        <!--
        Properties specific to this member
        -->
        <parameter name="properties">
            <property name="backendServerURL" value="https://${hostName}:${httpsPort}/services/"/>
            <property name="mgtConsoleURL" value="https://${hostName}:${httpsPort}/"/>
            <property name="subDomain" value="worker"/>
        </parameter>

        <!--
        Uncomment the following section to load custom Hazelcast data serializers.
        -->
        <!--
        <parameter name="hazelcastSerializers">
            <serializer typeClass="java.util.TreeSet">org.wso2.carbon.hazelcast.serializer.TreeSetSerializer
            </serializer>
            <serializer typeClass="java.util.Map">org.wso2.carbon.hazelcast.serializer.MapSerializer</serializer>
        </parameter>
        -->

        <!--
           The list of static or well-known members. These entries will only be valid if the
           "membershipScheme" above is set to "wka"
        -->
        <members>
            <member>
                <hostName>10.100.4.40</hostName>
                <port>4001</port>
            </member>
	    <member>
                <hostName>10.100.4.40</hostName>
                <port>4002</port>
            </member>
 <member>
                <hostName>10.100.4.40</hostName>
                <port>4003</port>
            </member>
	
        </members>

        <!--
        Enable the groupManagement entry if you need to run this node as a cluster manager.
        Multiple application domains with different GroupManagementAgent implementations
        can be defined in this section.
        -->
        <groupManagement enable="false">
            <applicationDomain name="wso2.as.domain"
                               description="AS group"
                               agent="org.wso2.carbon.core.clustering.hazelcast.HazelcastGroupManagementAgent"
                               subDomain="worker"
                               port="2222"/>
        </groupManagement>
    </clustering>
</axisconfig>
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to