title: SOAP HTTP Request Very Slow
body: <p>Im totally new to SOAP HTTP Requests. Can someone give me a broad rundown on things that might slow it down. Im working on a .NET application that uses SOAP, WSDL. The request is taking around 50 seconds, everytime. Im probably making no sense, so please excuse my ignorance. Could there be something I could do at my end, to allow the request to run without causing the page not to load. AJAX maybe.</p>
  
  <p>--M</p>
  
  <p><strong>Edit (09/08/2009):</strong></p>
  
  <p>OK, i've used SOAPUI and its coming up with two options WebServiceSoap12 and WebServiceSoap. The first one is goving me a speedy milliseconds response, and the second is giving me a "400 Bad Request. Why would I need that second one?</p>
  
  <p>Below is the WSDL</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://www.example.com" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://www.example.com" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"&gt;
    &lt;wsdl:types&gt;
      &lt;s:schema elementFormDefault="qualified" targetNamespace="http://www.example.com"&gt;
        &lt;s:element name="EventGetList"&gt;
          &lt;s:complexType&gt;
            &lt;s:sequence&gt;
              &lt;s:element minOccurs="0" maxOccurs="1" name="regionId" type="s:string" /&gt;
            &lt;/s:sequence&gt;
          &lt;/s:complexType&gt;
        &lt;/s:element&gt;
        &lt;s:element name="EventGetListResponse"&gt;
          &lt;s:complexType&gt;
            &lt;s:sequence&gt;
              &lt;s:element minOccurs="0" maxOccurs="1" name="EventGetListResult" type="tns:ArrayOfOpenEvent" /&gt;
            &lt;/s:sequence&gt;
          &lt;/s:complexType&gt;
        &lt;/s:element&gt;
        &lt;s:complexType name="ArrayOfOpenEvent"&gt;
          &lt;s:sequence&gt;
            &lt;s:element minOccurs="0" maxOccurs="unbounded" name="OpenEvent" nillable="true" type="tns:OpenEvent" /&gt;
          &lt;/s:sequence&gt;
        &lt;/s:complexType&gt;
        &lt;s:complexType name="OpenEvent"&gt;
          &lt;s:sequence&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Id" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Title" type="s:string" /&gt;
            &lt;s:element minOccurs="1" maxOccurs="1" name="EventStart" type="s:dateTime" /&gt;
            &lt;s:element minOccurs="1" maxOccurs="1" name="EventEnd" type="s:dateTime" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="RegionId" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="EventSubject" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="EventAdditionalDetails" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="EventDelivery" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Location" type="tns:EventLocation" /&gt;
            &lt;s:element minOccurs="1" maxOccurs="1" name="OnlineRegistrations" type="s:boolean" /&gt;
          &lt;/s:sequence&gt;
        &lt;/s:complexType&gt;
        &lt;s:complexType name="EventLocation"&gt;
          &lt;s:sequence&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Address1" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Address2" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Address3" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Town" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Postcode" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="AddressOther" type="s:string" /&gt;
          &lt;/s:sequence&gt;
        &lt;/s:complexType&gt;
        &lt;s:element name="EventRegisterClient"&gt;
          &lt;s:complexType&gt;
            &lt;s:sequence&gt;
              &lt;s:element minOccurs="0" maxOccurs="1" name="registration" type="tns:OpenEventRegistration" /&gt;
            &lt;/s:sequence&gt;
          &lt;/s:complexType&gt;
        &lt;/s:element&gt;
        &lt;s:complexType name="OpenEventRegistration"&gt;
          &lt;s:sequence&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="EventId" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="ForeName" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="Surname" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="TelephoneNumber" type="s:string" /&gt;
            &lt;s:element minOccurs="0" maxOccurs="1" name="EmailAddress" type="s:string" /&gt;
          &lt;/s:sequence&gt;
        &lt;/s:complexType&gt;
        &lt;s:element name="EventRegisterClientResponse"&gt;
          &lt;s:complexType&gt;
            &lt;s:sequence&gt;
              &lt;s:element minOccurs="1" maxOccurs="1" name="EventRegisterClientResult" type="s:boolean" /&gt;
            &lt;/s:sequence&gt;
          &lt;/s:complexType&gt;
        &lt;/s:element&gt;
      &lt;/s:schema&gt;
    &lt;/wsdl:types&gt;
    &lt;wsdl:message name="EventGetListSoapIn"&gt;
      &lt;wsdl:part name="parameters" element="tns:EventGetList" /&gt;
    &lt;/wsdl:message&gt;
    &lt;wsdl:message name="EventGetListSoapOut"&gt;
      &lt;wsdl:part name="parameters" element="tns:EventGetListResponse" /&gt;
    &lt;/wsdl:message&gt;
    &lt;wsdl:message name="EventRegisterClientSoapIn"&gt;
      &lt;wsdl:part name="parameters" element="tns:EventRegisterClient" /&gt;
    &lt;/wsdl:message&gt;
    &lt;wsdl:message name="EventRegisterClientSoapOut"&gt;
      &lt;wsdl:part name="parameters" element="tns:EventRegisterClientResponse" /&gt;
    &lt;/wsdl:message&gt;
    &lt;wsdl:portType name="WebServiceSBSpEventsSoap"&gt;
      &lt;wsdl:operation name="EventGetList"&gt;
        &lt;wsdl:input message="tns:EventGetListSoapIn" /&gt;
        &lt;wsdl:output message="tns:EventGetListSoapOut" /&gt;
      &lt;/wsdl:operation&gt;
      &lt;wsdl:operation name="EventRegisterClient"&gt;
        &lt;wsdl:input message="tns:EventRegisterClientSoapIn" /&gt;
        &lt;wsdl:output message="tns:EventRegisterClientSoapOut" /&gt;
      &lt;/wsdl:operation&gt;
    &lt;/wsdl:portType&gt;
    &lt;wsdl:binding name="WebServiceSBSpEventsSoap" type="tns:WebServiceSBSpEventsSoap"&gt;
      &lt;soap:binding transport="http://schemas.xmlsoap.org/soap/http" /&gt;
      &lt;wsdl:operation name="EventGetList"&gt;
        &lt;soap:operation soapAction="http://www.example.com/EventGetList" style="document" /&gt;
        &lt;wsdl:input&gt;
          &lt;soap:body use="literal" /&gt;
        &lt;/wsdl:input&gt;
        &lt;wsdl:output&gt;
          &lt;soap:body use="literal" /&gt;
        &lt;/wsdl:output&gt;
      &lt;/wsdl:operation&gt;
      &lt;wsdl:operation name="EventRegisterClient"&gt;
        &lt;soap:operation soapAction="http://www.example.com/EventRegisterClient" style="document" /&gt;
        &lt;wsdl:input&gt;
          &lt;soap:body use="literal" /&gt;
        &lt;/wsdl:input&gt;
        &lt;wsdl:output&gt;
          &lt;soap:body use="literal" /&gt;
        &lt;/wsdl:output&gt;
      &lt;/wsdl:operation&gt;
    &lt;/wsdl:binding&gt;
    &lt;wsdl:binding name="WebServiceSBSpEventsSoap12" type="tns:WebServiceSBSpEventsSoap"&gt;
      &lt;soap12:binding transport="http://schemas.xmlsoap.org/soap/http" /&gt;
      &lt;wsdl:operation name="EventGetList"&gt;
        &lt;soap12:operation soapAction="http://www.example.com/EventGetList" style="document" /&gt;
        &lt;wsdl:input&gt;
          &lt;soap12:body use="literal" /&gt;
        &lt;/wsdl:input&gt;
        &lt;wsdl:output&gt;
          &lt;soap12:body use="literal" /&gt;
        &lt;/wsdl:output&gt;
      &lt;/wsdl:operation&gt;
      &lt;wsdl:operation name="EventRegisterClient"&gt;
        &lt;soap12:operation soapAction="http://www.example.com/EventRegisterClient" style="document" /&gt;
        &lt;wsdl:input&gt;
          &lt;soap12:body use="literal" /&gt;
        &lt;/wsdl:input&gt;
        &lt;wsdl:output&gt;
          &lt;soap12:body use="literal" /&gt;
        &lt;/wsdl:output&gt;
      &lt;/wsdl:operation&gt;
    &lt;/wsdl:binding&gt;
    &lt;wsdl:service name="WebServiceSBSpEvents"&gt;
      &lt;wsdl:port name="WebServiceSBSpEventsSoap" binding="tns:WebServiceSBSpEventsSoap"&gt;
        &lt;soap:address location="http://www.example.com/webserviceexternal/WebServiceSBSpEvents.asmx" /&gt;
      &lt;/wsdl:port&gt;
      &lt;wsdl:port name="WebServiceSBSpEventsSoap12" binding="tns:WebServiceSBSpEventsSoap12"&gt;
        &lt;soap12:address location="http://www.example.com/webserviceexternal/WebServiceSBSpEvents.asmx" /&gt;
      &lt;/wsdl:port&gt;
    &lt;/wsdl:service&gt;
  &lt;/wsdl:definitions&gt;
  </code></pre>