Hello,
I have a JDBC inbound channel adapter with the target as a router channel. For some reason, only the first row is being sent to the router. My query takes all the rows with status as "new" and marks them as "processing" then it should send the rows (which are mapped to objects using a row mapper) to the router method. The router should send to the right SA for processing, then the SA should update the row as "SUCCESSFUL" or "FAILED." In my case, only the first row is being processed, and marked as "successful" and the subsequent rows are remaining in a "processing" state. Should I be using something between my inbound adapter and the router? Am I not able to directly send the List of objects to my router? Please advise (code snippet below) --
Code:<jdbc:inbound-channel-adapter query="${transaction.query}" max-rows-per-poll="${max.rows}" channel="transactions" data-source="dataSource" update="${update.query}" row-mapper="rowMapper"> <poller fixed-rate="${poll.rate}"> <transactional /> </poller> </jdbc:inbound-channel-adapter> <beans:bean id="rowMapper" class="com.bakeshop.integration.poller.SweetsTransactionRowMapper" /> <channel id="transactions"> <dispatcher task-executor="wmTaskExecutor" /> <interceptors> <wire-tap channel="logger" /> </interceptors> </channel> <logging-channel-adapter id="logger" level="ERROR" /> <channel id="cakes" /> <channel id="cookies" /> <channel id="cakeBaker" /> <channel id="cookieBaker" /> <bridge input-channel="cakes" output-channel="cakeBaker" /> <bridge input-channel="cookies" output-channel="cookieBaker" /> <stream:stdout-channel-adapter id="deliveries" /> <service-activator input-channel="cakeBaker" ref="requestProcessor" method="prepareCake" output-channel="deliveries"> <task:executor id="cake-pool" pool-size="${cake.pool}" /> </service-activator> <service-activator input-channel="cookieBaker" ref="requestProcessor" method="prepareCookie" output-channel="deliveries"> <task:executor id="cookie-pool" pool-size="${cookie.pool}" /> </service-activator> <beans:bean id="wmTaskExecutor" class="org.springframework.scheduling.commonj.WorkManagerTaskExecutor"> <beans:property name="workManagerName" value="wm/baker" /> </beans:bean> <!-- Dozer mapper --> <beans:bean id="mapper" class="org.dozer.DozerBeanMapper" scope="singleton" />


Reply With Quote
