none
The contract 'IMetadataExchange' in client configuration does not match the name in service contract.

    Question

  • I am trying to run a test WCF tutorial and getting an error when I attempt to run it via F5:

    "The contract 'IMetadataExchange' in client configuration does not match the name in service contract. To recover, please manually correct client configuration. Or check 'Always regenerate config when launching services' in the Tools->Options Menu, then refresh the service."

    I am unable to find this option in Tools->Options. However the problem seems to be an artifact of installing the adapter pack for the BizTalk Development edition on my laptop. It appears to be looking for things like IMetadataExchange (SAP), etc.
    Tuesday, November 17, 2009 10:16 PM

Answers

  • Hi,


    Check this ou

    http://azure.snagy.name/blog/?tag=imetadataexchange
    http://blogs.msdn.com/wcftoolsteamblog/archive/2008/08/28/tips-for-wcf-tools-in-vs2008-sp1.aspx
    Please mark the response as answers if it solves your question or vote as helpful if you find it helpful. http://thoughtorientedarchitecture.blogspot.com/
    • Proposed as answer by Haripraghash Wednesday, November 18, 2009 12:29 AM
    • Marked as answer by Bill2010 Wednesday, November 18, 2009 12:47 AM
    Wednesday, November 18, 2009 12:29 AM

All replies

  • Hi,


    Check this ou

    http://azure.snagy.name/blog/?tag=imetadataexchange
    http://blogs.msdn.com/wcftoolsteamblog/archive/2008/08/28/tips-for-wcf-tools-in-vs2008-sp1.aspx
    Please mark the response as answers if it solves your question or vote as helpful if you find it helpful. http://thoughtorientedarchitecture.blogspot.com/
    • Proposed as answer by Haripraghash Wednesday, November 18, 2009 12:29 AM
    • Marked as answer by Bill2010 Wednesday, November 18, 2009 12:47 AM
    Wednesday, November 18, 2009 12:29 AM
  • Hi, I too get the same error, however the client section for my machine.config looks different than the article :

    <client>
          <endpoint binding="sqlBinding" contract="IMetadataExchange"
          name="mssql" />
          <metadata>
            <policyImporters>
              <extension type="System.ServiceModel.Channels.ContextBindingElementImporter, system.workflowservices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL" />
            </policyImporters>
            <wsdlImporters>
              <extension type="System.ServiceModel.Channels.ContextBindingElementImporter, system.workflowservices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL" />
            </wsdlImporters>
          </metadata>
        </client>
    The end point's name here is mssql instead of sb. Can we follow the same troubleshooting steps in this case too?


    -Perennial Newbie-
    Friday, December 04, 2009 8:27 PM
  • Is there a better solution than commenting these Machine.config lines or uninstalling the BT SDK because I have BizTalk and use BizTalk including the SDK so uninstalling is not an option?
    Tuesday, February 21, 2012 6:39 PM
  • First of all, when in documentation is mentioned "Tools --> Options" for "Always regenerate config files..." option it does not mean: Visual Studio --> Tools --> Options :( It refers to WCF Test Client.

    Once WCF Test Client is started you can select "Always regenerate config files..." in Tools --> Options.

    Tuesday, September 03, 2013 11:11 AM