PrepAway - Latest Free Exam Questions & Answers

Which client endpoint configuration should you use?

You are developing an ASP.NET web application.
The application consumes a WCF service that implements a contract named IcontosoService.
The service is located on the local network and is exposed using the following endpoint <endpoint
name=”udpDiscover” kind=”udpDiscoveryEndpoint”/>
You need to consume the service by using the WS-Discovery protocol.
Which client endpoint configuration should you use?

PrepAway - Latest Free Exam Questions & Answers

A.
<endpoint name=”contosoEndpoint” address=”oneway-basic” binding=”basicHttpBinding”
contract=”IContosoService”/>

B.
<endpoint name=”contosoEndpoint” kind=”dynamicEndpoint” binding=”wsHttpBinding”
contract=”IContosoService”/>

C.
<endpoint name=”contosoEndpoint” address=”twoway-basic” binding=”basicHttpBinding”
contract=”IContosoService”/>

D.
<endpoint name=”contosoEndpoing” address=”dynamicEndpoint” binding=”wsHttpBinding” contract=”*”/>

Explanation:
http://msdn.microsoft.com/en-us/library/ee354381.aspx
kind=”dynamicEndpoint” Defines a standard endpoint configured to use WCF Discovery within a WCF client
application.
When using this standard endpoint, an address is not required because during the first call, the client will query
for a service endpoint matching the specified contract and automatically connect to it for you.
By default the discovery query is sent over multicast UDP but you can specify the discovery binding and search
criteria to use when you need to.
http://msdn.microsoft.com/en-us/library/ms731762.aspx
contract=”IContosoService” Required string attribute. A string that indicates which contract this endpoint is
exposing. The assembly must implement the contract type.


Leave a Reply