Results 1 to 6 of 6

Thread: How to write a concurrent web service client

Threaded View

  1. #1
    Join Date
    Oct 2008
    Location
    Minneapolis, MN
    Posts
    39

    Default How to write a concurrent web service client

    Hi, I have a requirement to parse a file that contains about 5,000 records and for each record, call a web service. Since each request can take up to 1 minute to get a response back, I would like to make the service calls concurrently. I am honestly not sure where to start and am looking for best practice suggestions.

    Here is how I have defined my spring beans (this actually works):
    Code:
        <bean id="xboxService" class="com.scranthdaddy.xbox.service.XboxServiceImpl">
            <property name="webServiceTemplate" ref="webServiceTemplate"/>
        </bean>
    
        <bean id="marshaller" class="org.springframework.oxm.xmlbeans.XmlBeansMarshaller"/>
    
        <bean id="webServiceTemplate" class="org.springframework.ws.client.core.WebServiceTemplate">
            <property name="defaultUri" value="http://xbox2.scranthdaddy.com"/>
    
            <property name="marshaller" ref="marshaller"/>
    
            <property name="unmarshaller" ref="marshaller"/>
        </bean>
    Thanks!
    Last edited by scranthdaddy; Dec 4th, 2010 at 12:55 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •