<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
	   xmlns:context="http://www.springframework.org/schema/context"
	   xmlns:gfe="http://www.springframework.org/schema/geode"
	   xmlns:util="http://www.springframework.org/schema/util"
	   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	   xsi:schemaLocation="
		http://www.springframework.org/schema/beans https://www.springframework.org/schema/beans/spring-beans.xsd
		http://www.springframework.org/schema/context https://www.springframework.org/schema/context/spring-context.xsd
	   	http://www.springframework.org/schema/geode https://www.springframework.org/schema/geode/spring-geode.xsd
		http://www.springframework.org/schema/util https://www.springframework.org/schema/util/spring-util.xsd
">

	<util:properties id="indexConfiguration">
		<prop key="index.complex.type">HASH</prop>
	</util:properties>

	<context:property-placeholder properties-ref="indexConfiguration"/>

	<!-- all beans are lazy to allow the same config to be used between multiple tests -->
	<!-- as there can be only one cache per VM -->

	<util:properties id="gemfireProperties">
		<prop key="name">IndexNamespaceTest</prop>
		<prop key="log-level">error</prop>
	</util:properties>

	<gfe:cache properties-ref="gemfireProperties"/>

	<gfe:replicated-region id="IndexedRegion" persistent="false"/>

	<gfe:index id="basic" expression="status" from="/IndexedRegion" type="functional"/>

	<gfe:index id="complex" name="complex-index" expression="tsi.name" from="/IndexedRegion tsi"
			   imports="import java.util" type="${index.complex.type}"/>

	<gfe:index id="index-with-ignore-and-override" expression="id" from="/IndexedRegion"
			   ignore-if-exists="true" override="true" type="PRIMARY_KEY"/>

</beans>
