Finding Something
Finding Something

Reputation: 31

There was no endpoint listening at "https://...." that could accept the message

<?xml version="1.0" ?>
<configuration>
<connectionStrings>
<add name="SqlServerConnectionString" connectionString=""/>
<add name="OracleConnectionString" connectionString="user id=DBGDEV;password=123;data source=(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=****.r..****)(PORT=1584))(CONNECT_DATA=(SERVICE_NAME=****)))" />
</connectionStrings>
<system.web>
<customErrors mode="Off"/>
<compilation debug="true">
</compilation>
</system.web>
<system.serviceModel>
<behaviors>
  <serviceBehaviors>
    <behavior name="serviceBehavior">         
       <serviceMetadata httpsGetEnabled="true"/>
      <serviceDebug includeExceptionDetailInFaults="false" />
    </behavior>
  </serviceBehaviors>
  <endpointBehaviors>
    <behavior name="httpEndpointBehavour">
      <webHttp/>
    </behavior>
  </endpointBehaviors>
</behaviors>
<services>
  <service name="Implementation.AccountService" behaviorConfiguration="serviceBehavior">
    <endpoint address="" binding="webHttpBinding" contract="Contract.IAccountService" behaviorConfiguration="httpEndpointBehavour"bindingConfiguration="webHttpBinding" />
    <endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
  </service>
</services>
  <bindings>
  <basicHttpBinding>
    <binding name="WCFsoap" closeTimeout="00:01:00" openTimeout="00:01:00"
        receiveTimeout="00:10:00" sendTimeout="00:01:00" allowCookies="false"
        bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
        maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
        messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
        useDefaultWebProxy="true">
       <security mode="Transport">
        <transport clientCredentialType="Basic" proxyCredentialType="Basic"
            realm="" />
        <message clientCredentialType="UserName" algorithmSuite="Default" />
      </security>
    </binding>
    <binding name="WCFsoap1" closeTimeout="00:01:00" openTimeout="00:01:00"
        receiveTimeout="00:10:00" sendTimeout="00:01:00" allowCookies="false"
        bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
        maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
        messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
        useDefaultWebProxy="true">
      <security mode="None">
        <transport clientCredentialType="None" proxyCredentialType="None"
            realm="" />
        <message clientCredentialType="UserName" algorithmSuite="Default"/>
      </security>
    </binding>
  </basicHttpBinding>
  <webHttpBinding>
    <binding name="webHttpBinding" closeTimeout="00:01:00" openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferSize="2147483647" maxReceivedMessageSize="2147483647" useDefaultWebProxy="true">
      <readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" />
      <security mode="Transport">
        <transport clientCredentialType="None" />
      </security>
    </binding>
  </webHttpBinding>
</bindings>
<client>
  <endpoint address="https://test.myservice.com/rally_generic_ws.do?SOAP"
           binding="basicHttpBinding" bindingConfiguration="WCFsoap"
           contract="serviceName.WCFsoap" name="WCFsoap" />
</client>
</system.serviceModel>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true">
</modules>
<validation validateIntegratedModeConfiguration="false" />
<handlers>
</handlers>
</system.webServer>
<system.codedom>    
</system.codedom>
<runtime>    
</runtime>
</configuration>

Above code is of Service web.config.

Error "There was no endpoint listening at "https://test.myservice.com/rally_generic_ws.do?SOAP" that could accept the message This is often caused by an incorrect address or SOAP action". What can be the reason for this error.I am blocked due to this.Please guide me.

Next Issue

After doing certain changes in my web.config when i add the https as service reference in wcf test client i get the below error. Cannot obtain Metadata from https://server-uat:8090/service.svc. If this is a Windows (R) Communication Foundation service to which you have access, please check that you have enabled metadata publishing at the specified address. For help enabling metadata publishing, please refer to the MSDN documentation at http://go.microsoft.com/fwlink/?LinkId=65455. WS-Metadata Exchange Error URI: https://server-uat:8090/service.svc Metadata contains a reference that cannot be resolved: 'http://192.168.0.15:8090/service.svc'.
There was no endpoint listening at https://test.myservice.com/rally_generic_ws.do?SOAP that could accept the message. This is often caused by an incorrect address or SOAP action.

See Inner Exception, if present, for more details.
The remote server returned an error: (404) Not Found.HTTP GET Error URI: https://server-uat:8090/service.svc

The document at the url https://server-uat:8090/service.svc was not recognized as a known document type.The error message from each known type may help you fix the problem:-

Report from 'https://server-uat:8090/service.svc' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.- The remote name could not be resolved: ' **********'- Report from 'WSDL Document' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.- Report from 'XML Schema' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.

This is the error what i get when i try to add the service to wcf test client.What is the reason for this error.How to get rid of this error.

According to my knowledge i guess the client couldn't find the requested action in the server.Do i need to change in web.config??

Upvotes: 1

Views: 21319

Answers (1)

slorello
slorello

Reputation: 46

The client's endpoints and the service's endpoints do no match

    <client>
    <endpoint binding="customBinding" bindingConfiguration="WebHttpBinding_ImyService"
        contract="IEventLoggerService" name="WebHttpBinding_ImyService" />
    </client>

<service name="Implementation.EventLoggerService" behaviorConfiguration="serviceBehavior">
    <endpoint address="" binding="webHttpBinding" contract="Contract.IAccountService" behaviorConfiguration="httpEndpointBehavour"bindingConfiguration="webHttpBinding" />
    <endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
</service>

If you look at the addresses of your services they clearly do no match the address that your client is listening to. additionally there is no service fulfilling the IEventLoggerService contract.

is it possible that you are missing a service endpoint?

EDIT:

The problem you are having is that this client endpoint in your web.config file does not have a service listening to it

<client>
  <endpoint address="https://test.myservice.com/rally_generic_ws.do?SOAP"
       binding="basicHttpBinding" bindingConfiguration="WCFsoap"
       contract="serviceName.WCFsoap" name="WCFsoap" />
</client>

Now I am making a big assumption here -> that the service who's reading your web.config file is meant to be both the producer and consumer of this service. Assuming that, I would suggest adding another Service endpoint nested within your services tags in the web.config file

<endpoint address = "https://test.myservicenowmyservice.com/rally_generic_ws.do?SOAP" 
contract = "serviceName.WCFSoap"  binding = "BasicHttpBinding" name ="WCFsoap"
bindingConfiguration ="WCFsoap"/>

Now if your service is meant to fulfill the serviceName.WCFSoap contract, this should work fine. If not, then you should ensure whatever service is meant to fulfill that contract does in fact have that endpoint.

Hope this helps

Upvotes: 1

Related Questions