Removed iBatis based components
This commit removes the iBatis based ItemReaders and ItemWriter. They were depricated in the 3.0 line in favor of the MyBatis natively provided ItemReader and ItemWriter implementations. This removes those depricated components. Resolves BATCH-2591
This commit is contained in:
@@ -1,7 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE sqlMapConfig PUBLIC "-//ibatis.apache.org//DTD SQL Map Config 2.0//EN"
|
||||
"http://ibatis.apache.org/dtd/sql-map-config-2.dtd">
|
||||
|
||||
<sqlMapConfig>
|
||||
<sqlMap resource="ibatis-customer-credit.xml"/>
|
||||
</sqlMapConfig>
|
||||
@@ -1,26 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE sqlMap PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN"
|
||||
"http://ibatis.apache.org/dtd/sql-map-2.dtd">
|
||||
|
||||
<sqlMap namespace="Customer">
|
||||
<resultMap id="result" class="org.springframework.batch.sample.domain.trade.CustomerCredit">
|
||||
<result property="name" column="NAME" />
|
||||
<result property="credit" column="CREDIT" />
|
||||
</resultMap>
|
||||
|
||||
<select id="getAllCustomerCreditIds" resultClass="int">
|
||||
select ID from CUSTOMER
|
||||
</select>
|
||||
|
||||
<select id="getAllCustomerCredits" resultMap="result">
|
||||
select ID, NAME, CREDIT from CUSTOMER
|
||||
</select>
|
||||
|
||||
<select id="getCustomerCreditById" parameterClass="int" resultMap="result">
|
||||
select NAME, CREDIT from CUSTOMER where ID = #value#
|
||||
</select>
|
||||
|
||||
<update id="updateCredit" parameterClass="org.springframework.batch.sample.domain.trade.CustomerCredit" >
|
||||
update CUSTOMER set CREDIT = #credit# where NAME = #name#
|
||||
</update>
|
||||
</sqlMap>
|
||||
@@ -1,23 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<beans xmlns="http://www.springframework.org/schema/beans"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
|
||||
|
||||
<bean id="itemReader"
|
||||
class="org.springframework.batch.item.database.IbatisPagingItemReader">
|
||||
<property name="queryId" value="getAllCustomerCredits" />
|
||||
<property name="sqlMapClient" ref="sqlMapClient" />
|
||||
<property name="dataSource" ref="dataSource"/>
|
||||
</bean>
|
||||
|
||||
<bean id="itemWriter"
|
||||
class="org.springframework.batch.item.database.IbatisBatchItemWriter">
|
||||
<property name="statementId" value="updateCredit" />
|
||||
<property name="sqlMapClient" ref="sqlMapClient" />
|
||||
<property name="dataSource" ref="dataSource"/>
|
||||
</bean>
|
||||
|
||||
<bean id="sqlMapClient" class="com.ibatis.sqlmap.client.SqlMapClientBuilder" factory-method="buildSqlMapClient">
|
||||
<constructor-arg value="ibatis-config.xml"/>
|
||||
</bean>
|
||||
</beans>
|
||||
Reference in New Issue
Block a user