How DCS Implements Policy Assertions

DCS provides an object model for building custom policies that extends the policy framework of WCF. WCF enables a service to export policy at three levels: message, operation, and binding.

  • WCF message-level policy assertions are useful if the request, response, and fault messages for an operation require different policies to be applied. This approach is very flexible, but increases overhead because the policies are defined in the metadata for each operation and message in the service. DCS operation-level policies are implemented by using WCF message-level policy assertions.
  • WCF operation-level policy assertions enable different operations in a service to specify their own policies, separate from those of other operations in the same service. The same policy applies to request, response, and fault messages for an operation. DCS does not use WCF operation-level policy assertions.
  • WCF binding-level policy assertions apply the same policy to all operations in a service. They carry less overhead than message-level policy assertions because they are defined only once in the service metadata. DCS service-level policies are implemented by using WCF binding-level policy assertions.

For more information on the classes and interfaces that DCS provides to enable you to implement a custom policy, see Custom Policy Reference.

See Also

Custom Policy Reference