Search code examples
wcf

AddressFilter mismatch at the EndpointDispatcher - the msg with To


Any ideas how I correct this.. calling a service via js

The message with To 'http://MySite.svc/GetStateXML' cannot be processed at the receiver, due to an AddressFilter mismatch at the EndpointDispatcher. Check that the sender and receiver's EndpointAddresses agree

thanks


Solution

  • Look at <webHttp />

    <services>
          <service name="SimpleService.SimpleService" behaviorConfiguration="serviceBehaviour">
            <endpoint address="" binding="webHttpBinding" contract="SimpleService.ISimpleService" behaviorConfiguration="web">
            </endpoint>
            <endpoint address="mex"
                  binding="mexHttpBinding"
                  contract="IMetadataExchange">
            </endpoint>
          </service>
        </services>
    
    ....
    ....
    
    <endpointBehaviors>
            <behavior name="web">
              <webHttp />
            </behavior>
    </endpointBehaviors>