Structure of the WCF configuration file

Source: Internet
Author: User

Structure of the WCF configuration file:

< System. servicemodel >
<! -- Server-side WCF Service Configuration -->
< Services >
<! -- Use the configuration file to start metadata exchange so that you can access -->
< Service Behaviorconfiguration = "Testbehavior" Name = "Namespace. testclass" >
<! --
Endpoint: the endpoint is related to the address, binding, and contract. The address defines the service location, the binding defines the service communication mode, and the contract defines the service content.
If the address is empty, the base address is used.
The configuration file can be used to customize the binding used by the endpoint, that is, to add the bindingconfiguration attribute. Its value should be consistent with the custom binding name in the <bindings> Configuration section.
-->
< Endpoint Address = "" Binding = "Basichttpbinding" Bindingconfiguration = "Basichttpbinding_itest" Contract = "Namespace. itestinterface" >
< Identity >
<! -- Only Local calls are allowed -->
< DNS Value = "Localhost" />
</ Identity >
</ Endpoint >
<! -- Metadata Exchange -->
< Endpoint Address = "Mex" Binding = "Mexhttpbinding" Contract = "Imetadataexchange" />
</ Service >
</ Services >

<! -- Metadata Exchange behavior Configuration -->
< Behaviors >
< Servicebehaviors >
< Behavior Name = "Testbehavior" >
<! -- Metadata Exchange Based on HTTP-GET -->
< Servicemetadata Httpgetenabled = "True" />
<! -- Displays detailed exception information -->
< Servicedebug Includeexceptiondetailinfaults = "True" />
</ Behavior >
</ Servicebehaviors >
</ Behaviors >

<! -- Custom binding -->
< Bindings >
< Basichttpbinding >
< Binding Name = "Basichttpbinding_itest" Messageencoding = "Text" Textencoding = "UTF-8" Transfermode = "Buffered" Usedefawebwebproxy = "True" >
< Readerquotas Maxdepth = "32" Maxstringcontentlength = "8192" Maxarraylength = "16384" Maxbytesperread = "4096" Maxnametablecharcount = "16384" />
< Security Mode = "NONE" >
< Transport Clientcredentialtype = "NONE" Proxycredentialtype = "NONE" Realm = "" />
< Message Clientcredentialtype = "Username" Algorithmsuite = "Default" />
</ Security >
</ Binding >
</ Basichttpbinding >
</ Bindings >
</ System. servicemodel >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.