/hazelcast-spring/src/test/resources/com/hazelcast/spring/node-client-applicationContext-hazelcast.xml
https://bitbucket.org/gabral6_gmailcom/hazelcast · XML · 96 lines · 73 code · 8 blank · 15 comment · 0 complexity · 39a0598c876b8eb359d4a1fe6204d44b MD5 · raw file
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- ~ Copyright (c) 2008-2013, Hazelcast, Inc. All Rights Reserved.
- ~
- ~ 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.
- -->
- <beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:p="http://www.springframework.org/schema/p"
- xmlns:hz="http://www.hazelcast.com/schema/spring"
- xsi:schemaLocation="http://www.springframework.org/schema/beans
- http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
- http://www.hazelcast.com/schema/spring
- http://www.hazelcast.com/schema/spring/hazelcast-spring-2.5.xsd">
- <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"
- p:systemPropertiesModeName="SYSTEM_PROPERTIES_MODE_OVERRIDE">
- <property name="locations">
- <list>
- <value>classpath:/hazelcast-default.properties</value>
- </list>
- </property>
- </bean>
- <hz:hazelcast id="instance">
- <hz:config>
- <hz:group
- name="${cluster.group.name}"
- password="${cluster.group.password}"/>
- <hz:properties>
- <hz:property name="hazelcast.merge.first.run.delay.seconds">5</hz:property>
- <hz:property name="hazelcast.merge.next.run.delay.seconds">5</hz:property>
- </hz:properties>
- <hz:network port="${cluster.port}" port-auto-increment="false">
- <hz:join>
- <hz:multicast enabled="false"
- multicast-group="224.2.2.3"
- multicast-port="54327"/>
- <hz:tcp-ip enabled="true">
- <hz:members>${cluster.members}</hz:members>
- </hz:tcp-ip>
- </hz:join>
- <hz:interfaces enabled="false">
- <hz:interface>10.10.1.*</hz:interface>
- </hz:interfaces>
- </hz:network>
- </hz:config>
- </hz:hazelcast>
- <hz:client id="client"
- group-name="${cluster.group.name}" group-password="${cluster.group.password}"
- connect-attempt-limit="3" connect-timeout="1000"
- reconnect-attempt-limit="2" reconnect-timeout="3000"
- auto-update-members="false" shuffle-members="true">
- <hz:member>127.0.0.1:5700</hz:member>
- <hz:member>127.0.0.1:5701</hz:member>
- </hz:client>
- <hz:client id="client2"
- connect-attempt-limit="3" connect-timeout="1000"
- reconnect-attempt-limit="2" reconnect-timeout="3000"
- auto-update-members="false" shuffle-members="true" credentials-ref="credentials" >
- <hz:member>127.0.0.1:5700</hz:member>
- <hz:member>127.0.0.1:5701</hz:member>
- </hz:client>
- <bean id="credentials" class="com.hazelcast.security.UsernamePasswordCredentials">
- <property name="username" value="spring-group" />
- <property name="password" value="spring-group-pass" />
- </bean>
- <hz:map id="map1" instance-ref="client" name="map1"/>
- <hz:map id="map2" instance-ref="client" name="map2"/>
- <hz:multiMap id="multiMap" instance-ref="client" name="multiMap"/>
- <hz:queue id="queue" instance-ref="client" name="queue"/>
- <hz:topic id="topic" instance-ref="client" name="topic"/>
- <hz:set id="set" instance-ref="client" name="set"/>
- <hz:list id="list" instance-ref="client" name="list"/>
- <hz:executorService id="executorService" instance-ref="client" name="executorService"/>
- <hz:idGenerator id="idGenerator" instance-ref="client" name="idGenerator"/>
- <hz:atomicNumber id="atomicNumber" instance-ref="client" name="atomicNumber"/>
- <hz:countDownLatch id="countDownLatch" instance-ref="client" name="countDownLatch"/>
- <hz:semaphore id="semaphore" instance-ref="client" name="semaphore"/>
- </beans>