Girish
Girish

Reputation: 447

How Session is maintain in WCF?

I have a WCF project. I want to implement session in my project.

How is session maintained by BasicHttpBinding and NetTcpBinding?

Upvotes: 0

Views: 331

Answers (1)

Seymour
Seymour

Reputation: 7067

A session-based binding supports the default association of a service instance with a particular session. However, different session-based bindings support different features in addition to enabling the session-based instancing control previously described.

WCF provides the following types of session-based application behavior:

  • The System.ServiceModel.Channels.SecurityBindingElement supports security-based sessions, in which both ends of communication have agreed upon a specific secure conversation. For more information, see Securing Services. For example, the System.ServiceModel.WSHttpBinding binding, which contains support for both security sessions and reliable sessions, by default uses only a secure session that encrypts and digitally signs messages.
  • The System.ServiceModel.NetTcpBinding binding supports TCP/IP-based sessions to ensure that all messages are correlated by the connection at the socket level.
  • The System.ServiceModel.Channels.ReliableSessionBindingElement element, which implements the WS-ReliableMessaging specification, provides support for reliable sessions in which messages can be configured to be delivered in order and exactly once, ensuring messages are received even when messages travel across multiple nodes during the conversation. For more information, see Reliable Sessions.
  • The System.ServiceModel.NetMsmqBinding binding provides MSMQ datagram sessions. For more information, see Queues in Windows Communication Foundation.

http://msdn.microsoft.com/en-us/library/ms733040(v=vs.110).aspx
http://msdn.microsoft.com/en-us/library/ff183865.aspx

Upvotes: 1

Related Questions