Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

Discovery Versioning

This topic provides a brief overview of the implementation of some new discovery features. It also gives an overview on how to select the discovery version to use.

The discovery feature includes support for three versions of the WS_Discovery protocol. The discovery APIs allow you to select which version of the protocol you want to use. This document briefly describes the versioning-related settings.

The following Discovery classes now have a DiscoveryVersion property and take a DiscoveryVersion argument in their constructors:

Dd456799.collapse_all(en-us,VS.110).gifDiscoveryVersion.WSDiscoveryApril2005

ProvidingWSDiscoveryApril2005 as a constructor parameter makes the implementation use the April2005 version of the WS-Discovery protocol. This version corresponds to the published version of the WS-Discovery protocol specification. This version should be used to interoperate with legacy application utilizing the April2005 version of WS-Discovery.

Dd456799.collapse_all(en-us,VS.110).gifDiscoveryVersion.WSDiscovery11

The default discovery version used by the APIs isWSDiscovery11. This is the current standardized version of the WS-Discovery protocol.

Providing WSDiscoveryCD1 as a constructor parameter makes the implementation use the committee draft 1 version of the WS-Discovery protocol. This version of the protocol should be used to interoperate with implementations running the CD1 version of the WS-Discovery protocol.

You may want to expose multiple UDP Discovery Endpoints for different discovery versions on a single service host. To do this you must specify a unique address for each UDP discovery endpoint. The following example shows how to do this.

UdpDiscoveryEndpoint newVersionUdpEndpoint = new UdpDiscoveryEndpoint(DiscoveryVersion.WSDiscovery11);
UdpDiscoveryEndpoint oldVersionUdpEndpoint = new UdpDiscoveryEndpoint(DiscoveryVersion.WSDiscoveryApril2005);

newVersionUdpEndpoint.Address = new EndpointAddress(newVersionUdpEndpoint.Address.Uri.ToString() + "/version11");
oldVersionUdpEndpoint.Address = new EndpointAddress(oldVersionUdpEndpoint.Address.Uri.ToString() + "/versionAril2005");

serviceHost.AddServiceEndpoint(newVersionUdpEndpoint);
serviceHost.AddServiceEndpoint(oldVersionUdpEndpoint);

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.