Inside the Standard Bindings: WSDualHttp
Index for bindings in this series:
After a few days break, the series on standard bindings continues. This week will take care of the remainder of the HTTP bindings, leaving only the MSMQ and PeerChannel bindings to talk about. WSDualHttp features the same support for Web Service protocols as the WSHttp binding, but is designed for use with duplex contracts.
Standard disclaimer:
I've cut down on the number of properties presented by eliminating duplicates between the binding settings and binding element settings. For instance, the XML reader quotas can be set on either the binding or the message encoder binding element, but I'm only going to show them on the message encoder. I've also omitted most of the security credential settings because they're very messy and you hopefully won't need to change them much.
Unlike WSHttp, WSDualHttp only supports SOAP security. I'll start off with the settings when no security is being used. The other two big differences you'll see between WSHttp and WSDualHttp is that the dual variety makes Reliable Messaging mandatory and adds a CompositeDuplex binding element to provide the duplex shape.
System.ServiceModel.Channels.TransactionFlowBindingElement
TransactionProtocol: WSAtomicTransactions
System.ServiceModel.Channels.ReliableSessionBindingElement
AcknowledgementInterval: 00:00:00.2000000 EnableFlowControl: True InactivityTimeout: 00:10:00 MaxPendingChannels: 128 MaxRetryCount: 8 MaxTransferWindowSize: 32 Ordered: True
System.ServiceModel.Channels.CompositeDuplexBindingElement
ClientBaseAddress:
System.ServiceModel.Channels.TextMessageEncodingBindingElement
AddressingVersion: Addressing10 (https://www.w3.org/2005/08/addressing) MaxReadPoolSize: 64 MaxWritePoolSize: 16 ReaderQuotas: MaxArrayLength: 16384 MaxBytesPerRead: 4096 MaxDepth: 32 MaxNameTableCharCount: 16384 MaxStringContentLength: 8192
System.ServiceModel.Channels.HttpTransportBindingElement
AllowCookies: False AuthenticationScheme: Anonymous BypassProxyOnLocal: False HostNameComparisonMode: StrongWildcard ManualAddressing: False MappingMode: SoapWithWSAddressing MaxBufferPoolSize: 524288 MaxBufferSize: 65536 MaxReceivedMessageSize: 65536 ProxyAddress: ProxyAuthenticationScheme: Anonymous Realm: Scheme: http TransferMode: Buffered UnsafeConnectionNtlmAuthentication: False UseDefaultWebProxy: True
The CompositeDuplex element creates the back channel from the server to the client using the base address setting. Most configuration settings are unchanged from the ones used with the WSHttp binding except that there is no longer a switch to disable reliable sessions.
CloseTimeout: 00:01:00
EnvelopeVersion: Soap12 (https://www.w3.org/2003/05/soap-envelope)
Namespace: https://tempuri.org/
OpenTimeout: 00:01:00
ReceiveTimeout: 00:01:00
SendTimeout: 00:01:00
TextEncoding: System.Text.UTF8Encoding
TransactionFlow: False
Setting the Security.Mode to Message makes exactly the same transformation as we've seen with the other standard bindings.
- System.ServiceModel.Channels.TransactionFlowBindingElement
- System.ServiceModel.Channels.ReliableSessionBindingElement
- System.ServiceModel.Channels.SymmetricSecurityBindingElement
- System.ServiceModel.Channels.CompositeDuplexBindingElement
- System.ServiceModel.Channels.TextMessageEncodingBindingElement
- System.ServiceModel.Channels.HttpTransportBindingElement
The same holds true for changing the message encoding to use MTOM.
- System.ServiceModel.Channels.TransactionFlowBindingElement
- System.ServiceModel.Channels.ReliableSessionBindingElement
- System.ServiceModel.Channels.CompositeDuplexBindingElement
- System.ServiceModel.Channels.MtomMessageEncodingBindingElement
- System.ServiceModel.Channels.HttpTransportBindingElement
Next time: Inside the Standard Bindings: WSFederationHttp
Comments
- Anonymous
June 22, 2006
When you build a channel factory or listener, you have to specify a TChannel parameter that describes... - Anonymous
July 29, 2006
I thought I'd share the binding inspector program I wrote a few months ago to explore the different settings... - Anonymous
August 30, 2006
The CompositeDuplex channel is one of the two shape-changing channels that we’ve included in the product...