tags:

views:

250

answers:

3

I am not able to open the meta data url - http://localhost:8082/Tasks/mex I have added the mexhttpBinding in the config file. Can I see this mex endpoint in browser?

The config files look like:

<endpoint address="mex"  binding="mexHttpBinding"  contract="IMetadataExchange" />

Questions:

Is Mex is differ from WSDL? If no, why do we require MEX endpoing over WSDL?

In the WSDL, I see the WSDL types information missing. Is it by default? Can I look at the type information in WSDL?

Thanks in advance.

A: 

Aakash, Did you add a service behavior with a <serviceMetadata> element? It can be empty, i.e. <serviceMetadata />, but it must be present. The service definition needs to reference the service behaviorConfiguration. Check out the following for examples:

http://www.request-response.com/blog/PermaLink,guid,c9513d28-f580-4a33-b4e8-c15476799a9d.aspx

Keith Robertson
A: 

If you look at that endpoint, you'll see it looks like every other endpoint. There's even a service contract (IMetadataExchange). You can look at System.ServiceModel.Description.IMetadataExchange and see what that contract is all about.

John Saunders
A: 

Aakash,

Check out serviceMetadata for more information regarding the WCF configuration file.

To answer your questions though, MEX is a newer W3C standard for the presentation of Service description information, WSDL was the previous method. If you need to allow older clients to access your service description information, you may have to expose that information via WSDL.

The information for exposing your service description information as WSDL (httpGetEnabled) is also in the link provided above.

Also, try using the wcftestclient.exe to access your WCF service. It provides more functionality and information that a browser.

Cheers

Dave

Dave White