0

I have a service deployed in IIS and the service under the node of defaultwebsite ->Example.SampleService underneath i have the SVC file called SampleService.svc so,m when I browse it in IE like http://localhost/Example.SampleService/SampleService.svc the brwoser shows it fine. I try to test it with SOAP UI by adding the wsdl with same address as mentioned about the project got created in SOAPUI but when I submit the request I get the error like : HTTP/1.1 404 Not Found Cache-Control: private Server: Microsoft-IIS/7.5 X-AspNet-Version: 4.0.30319 X-Powered-By: ASP.NET Date: Mon, 19 Oct 2015 07:54:36 GMT Content-Length: 0

web.confg has below:

 <bindings>
  <wsHttpBinding>
    <binding name="wsUserName" maxReceivedMessageSize="262144" receiveTimeout="00:10:00" sendTimeout="00:10:00" openTimeout="00:10:00" closeTimeout="00:10:00">
      <security mode="Transport">
        <!--<message clientCredentialType="UserName" negotiateServiceCredential="false" establishSecurityContext="false" />-->
        <transport clientCredentialType="None" />
      </security>
    </binding>
  </wsHttpBinding>
</bindings>
<services>
  <service name="Example.SampleService.SampleService">
    <host>
      <baseAddresses>
        <add baseAddress="http://localhost/Example.SampleService/"  />
      </baseAddresses>
    </host>
    <endpoint address="" binding="wsHttpBinding" bindingConfiguration="wsUserName" contract="Example.IVaultService" />
    <endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
  </service>
</services>
<behaviors>
  <serviceBehaviors>
    <behavior>
       <!--To avoid disclosing metadata information, set the values below to false before deployment--> 
      <serviceMetadata httpGetEnabled="true" httpsGetEnabled="true"/>
       <!--To receive exception details in faults for debugging purposes, set the value below to true.  Set to false before deployment to avoid disclosing exception information--> 
      <serviceDebug includeExceptionDetailInFaults="false"/>
      <serviceCredentials useIdentityConfiguration="true">


      </serviceCredentials>

    </behavior>
  </serviceBehaviors>
</behaviors>
user3264937
  • 81
  • 14
  • Did you test it first with WCF test client (https://msdn.microsoft.com/en-us/library/bb552364.aspx) ? This is the most obvious way, before trying SoapUI – Mimas Oct 20 '15 at 13:41

1 Answers1

0

To import your service into SoapUI you need WSDL description. To get it use one of the following URI: http://localhost/Example.SampleService/SampleService.svc?singleWsdl or http://localhost/Example.SampleService/SampleService.svc?wsdl

Before you must enable publishing of metadata.

<serviceBehaviors>
  <behavior name="GlobalBehavior">
    <serviceMetadata httpGetEnabled="true" httpsGetEnabled="true" />
  </behavior>
</serviceBehaviors>

add to your service behaviorConfiguration="GlobalBehavior"

Mimas
  • 525
  • 3
  • 7
  • I am able to add the WSDL in SOAPUI and it generates methods as well while calling SOAP UI says not found error as mentioned in my post. btw, I haveservice behaviour defined already. updated the post – user3264937 Oct 19 '15 at 22:01