<serviceDebug>
Specifies debugging and help information features for a Windows Communication Foundation (WCF) service.
<system.serviceModel>
<behaviors>
<serviceBehaviors>
<behavior> of <serviceBehaviors>
<serviceDebug>
<serviceDebug httpHelpPageEnabled="Boolean"
httpHelpPageUrl="Uri"
httpsHelpPageEnabled="Boolean"
httpsHelpPageUrl="Uri"
includeExceptionDetailInFaults="Boolean" />
Attributes and Elements
The following sections describe attributes, child elements, and parent elements.
Attributes
Attribute | Description | ||
---|---|---|---|
httpHelpPageEnabled |
A Boolean value that controls whether WCF publishes an HTML help page at the address specified by the httpHelpPageUrl attribute. The default is true. You can set this property to false to disable the publication of an HTML help page visible to HTML browsers. To ensure the HTML help page is published at the location controlled by the httpHelpPageUrl attribute, you must set this attribute to true. In addition, one of the following conditions must also be met:
Although an exception is thrown if an absolute address that does not support the HTTP protocol scheme is assigned to the httpHelpPageUrl attribute, any other scenario in which neither of the preceding criteria is met results in no exception and no HTML help page. |
||
httpHelpPageUrl |
A URI that specifies the relative or absolute HTTP-based URL of the custom HTML help file the user sees when the endpoint is viewed using an HTML browser. You can use this attribute to enable the use of a custom HTML help file that is returned from an HTTP/Get request, for example, from an HTML browser. The location of the HTML help file is resolved as follows.
This attribute is valid only when the httpHelpPageEnabled attribute is true. |
||
httpsHelpPageEnabled |
A Boolean value that controls whether WCF publishes an HTML help page at the address specified by the httpsHelpPageUrl attribute. The default is true. You can set this property to false to disable the publication of an HTML help page visible to HTML browsers. To ensure the HTML help page is published at the location controlled by the httpsHelpPageUrl attribute, you must set this attribute to true. In addition, one of the following conditions must also be met:
Although an exception is thrown if an absolute address that does not support the HTTPS protocol scheme is assigned to the httpsHelpPageUrl attribute, any other scenario in which neither of the preceding criteria is met results in no exception and no HTML help page. |
||
httpsHelpPageUrl |
A URI that specifies the relative or absolute HTTPS-based URL of the custom HTML help file the user sees when the endpoint is viewed using an HTML browser. You can use this attribute to enable the use of a custom HTML help file that is returned from an HTTPS/Get request, for example, from an HTML browser. The location of the HTML help file is resolved as follows:
This attribute is valid only when the httpHelpPageEnabled attribute is true. |
||
includeExceptionDetailInFaults |
A value that specifies whether to include managed exception information in the detail of SOAP faults returned to the client for debugging purposes. The default is false. If you set this attribute to true, you can enable the flow of managed exception information to the client for debugging purposes, as well as the publication of HTML information files for users browsing the service in Web browsers.
|
Child Elements
None.
Parent Elements
Element | Description |
---|---|
Specifies a behavior element. |
Remarks
Setting includeExceptionDetailInFaults to true allows the service to return any exception that is thrown by the application code even if the exception is not declared using the FaultContractAttribute. This setting is useful when debugging cases where the server is throwing an unexpected exception.
You can also set httpsHelpPageEnabled and httpsHelpPageUrl to enable or disable the help page. Each service can optionally expose a help page that contains information about the service including the endpoint to get WSDL for the service. This can be enabled by setting httpHelpPageEnabled to true. This enables the help page to be returned to a GET request to the base address of the service. You can change this address by setting another attribute httpHelpPageUrl. You can make this secure by using HTTPS instead of HTTP.
See Also
Reference
Send comments about this topic to Microsoft.
© Microsoft Corporation. All rights reserved.