<?xml version="1.0" encoding="UTF-8"?>
<beans:beans xmlns="http://www.springframework.org/schema/batch" xmlns:beans="http://www.springframework.org/schema/beans"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://www.springframework.org/schema/batch http://www.springframework.org/schema/batch/spring-batch-2.2.xsd
	http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd">

	<beans:import resource="common-context.xml" />

	<job id="job1">
		<step id="s1" parent="step1" next="job1.flow" />
		<step id="job1.flow" next="s4">
			<flow parent="flow" />
		</step>
		<step id="s4" parent="step4" />
	</job>

	<job id="job2">
		<step id="job2.s1" parent="step1" next="job2.flow" />
		<step id="job2.flow" parent="flow.step" next="job2.s4" />
		<step id="job2.s4" parent="step4" />
	</job>

	<job id="job3">
		<decision decider="decider" id="job3.d1">
			<next on="OK" to="job3.flow" />
			<end on="END" />
		</decision>
		<step id="job3.flow" parent="flow.step" next="job3.d1" />
	</job>

	<job id="job4">
		<step id="job4.flow" parent="startable">
			<flow parent="flow" />
			<fail on="*" />
		</step>
	</job>

	<!-- BATCH-1745: awkward parent bean for allow-start-if-complete -->
	<beans:bean id="startable" abstract="true">
		<beans:property name="allowStartIfComplete" value="true" />
	</beans:bean>

	<flow id="flow" abstract="true">
		<step id="s2" parent="step2" next="s3" />
		<step id="s3" parent="step3" />
	</flow>

	<step id="flow.step" abstract="true">
		<flow parent="flow" />
	</step>

	<beans:bean id="decider" class="org.springframework.batch.core.configuration.xml.FlowStepParserTests$Decider" />

</beans:beans>