<?xml version="1.0" encoding="UTF-8"?>

<!--
     !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
           MANAGED WITH ANSIBLE
               DO NOT EDIT
     !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-->

<!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF 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.
-->

<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:util="http://www.springframework.org/schema/util"
       xsi:schemaLocation="
            http://www.springframework.org/schema/beans
            http://www.springframework.org/schema/beans/spring-beans.xsd
            http://www.springframework.org/schema/util
            http://www.springframework.org/schema/util/spring-util.xsd">
    <import resource="ignite-base-config.xml"/>
    <bean abstract="false"  id="ignIgniteConfiguration" class="org.apache.ignite.configuration.IgniteConfiguration" parent="base-ignite.cfg">
        <property name="workDirectory"           value="/gridgain/ssd/ignite_work_yardstick"/>
        <property name="discoverySpi">
            <bean class="org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi">
                <property name="localPort"      value="47500"/>
                <property name="localPortRange" value="9"/>
                <property name="ipFinder">
                   <bean class="org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder">
                        <property name="addresses">
                            <list>
                                 <value>10.116.214.199:47500</value>
                                 <value>10.116.214.200:47500</value>
                                 <value>10.116.214.201:47500</value>
                                 <value>10.116.214.202:47500</value>
                            </list>
                        </property>
                   </bean>
                </property>
            </bean>
        </property>
        <property name="binaryConfiguration">
            <bean class="org.apache.ignite.configuration.BinaryConfiguration">
                <property name="compactFooter" value="false"/>
            </bean>
        </property>
        <property name="dataStorageConfiguration">
            <ref bean="ignDataStorageConfiguration"/>
        </property>
        <property name="transactionConfiguration">
            <ref bean="ignTransactionConfiguration"/>
        </property>
    </bean>

    <bean id="ignDataStorageConfiguration" class="org.apache.ignite.configuration.DataStorageConfiguration">
        <!-- Overrides configuration of default data region which is created automatically. -->
        <property name="defaultDataRegionConfiguration">
            <ref bean="ignDefaultDataRegionConfiguration"/>
        </property>

        <property name="walMode" value="LOG_ONLY"/>
    </bean>

    <bean id="ignDefaultDataRegionConfiguration" class="org.apache.ignite.configuration.DataRegionConfiguration">
        <!-- Sets data region name. The name must be non empty and must not be equal to the reserved 'sysMemPlc' one. -->
        <!-- org.apache.ignite.configuration.DataStorageConfiguration.DFLT_DATA_REG_DEFAULT_NAME = "default" -->
        <property name="name"                     value="default"/>
        <property name="persistenceEnabled"       value="true"/>
        <property name="initialSize"              value="#{ 50L * 1024 * 1024}"/>
        <property name="maxSize"                  value="#{ 500L * 1024 * 1024}"/>
        <property name="metricsEnabled"           value="true"/>
    </bean>

    <!-- TransactionConfiguration -->
    <bean id="ignTransactionConfiguration"  class="org.apache.ignite.configuration.TransactionConfiguration">
        <property name="defaultTxIsolation"              value="READ_COMMITTED"/>
        <property name="defaultTxTimeout"                value="300000"/>
        <property name="txTimeoutOnPartitionMapExchange" value="10000"/>
    </bean>

</beans>