on 08-29-2019 6:57 AM
Hi All,
We have a requirement to make both async and sync calls for few methods and i have made the following spring configuration in the spring.xml:
<inbound-channel-adapter channel="customerChannel" auto-startup="true" ref="customerBean" method="prepareMessage" >
<!--Triggers for every 12 AM in a day-->
<poller cron="${customer.cron.expression}"></poller>
</inbound-channel-adapter>
<service-activator input-channel="updateCustomerLocationsB2BUnitChannel" ref="updateCustomerB2BUnit" method="loadCustomerLocationsB2Bunits" output-channel="endChannel" />
<service-activator input-channel="updateCustomerLocationsChannel" ref="updateCustomerLocations" method="loadCustomerLocations" output-channel="endChannel"/>
<service-activator input-channel="updateCustomerSalesOrgChannel" ref="updateCustomerSalesOrg" method="updateCustomerSalesOrg" output-channel="endChannel"/>
<recipient-list-router id="updateCustomerListRouter" input-channel="customerChannel">
<recipient channel="updateCustomerLocationsB2BUnitChannel" />
<recipient channel="updateCustomerLocationsChannel" />
<recipient channel="updateCustomerSalesOrgChannel" />
</recipient-list-router>
With the above configuration i am able to call only methods asynchronous but i have to call one after the other as well.
Requirement:
loadCustomerLocationsB2Bunits
loadCustomerLocations
updateCustomerSalesOrg
All the methods should execute at a time and after completion of execution of one method the other should execute i.e.,
loadCustomerLocationsB2Bunits -> loadCustomerLocations -> updateCustomerSalesOrg
Thanks,
G Gopinath.
User | Count |
---|---|
8 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.