WCF:Why we need the sessions?



WCF:Why we need the sessions?..

Answer / bhuwanesh

To co-relate all the messages sent between two endpoints.

WCF sessions have the following main conceptual features:

* They are explicitly initiated and terminated by the
calling application.

* Messages delivered during a session are processed in
the order in which they are received.

* Sessions correlate a group of messages into a
conversation. The meaning of that correlation is an
abstraction. For instance, one session-based channel may
correlate messages based on a shared network connection
while another session-based channel may correlate messages
based on a shared tag in the message body. The features that
can be derived from the session depend on the nature of the
correlation.

* There is no general data store associated with a WCF
session.

When a service contract specifies that it requires a
session, that contract is specifying that all calls (that
is, the underlying message exchanges that support the calls)
must be part of the same conversation. If a contract
specifies that it allows sessions but does not require one,
clients can connect and either establish a session or not
establish a session. If the session ends and a message is
sent through the same channel an exception is thrown.

Except basichttpbinding, wsHttpBinding and NetTcpBinding
supports session.

Is This Answer Correct ?    2 Yes 1 No

Post New Answer

More WCF Interview Questions

How many types of various programming approaches used for WCF?

0 Answers   Viscus Infotech,


What are the different platforms where we can host wcf service ?

0 Answers  


What is "know types" in wcf?

0 Answers  


What is the elements of WCF service used in client side?

0 Answers  


WCF:What is it the Dead-letter queue and the Poison queue? What is the difference?

1 Answers  






What is the address formats of the wcf transport schemas?

0 Answers  


how many types of contract does WCF defines?

0 Answers  


What is mean by wcf?

0 Answers  


In WCF what are duplex contracts?

0 Answers  


Which bindings in wcf support the message streaming?

0 Answers  


explain wcf web service (ws) binding type? : Wcf data services

0 Answers  


WCF:Could the IIS-hosted WCF service make use of HTTP transport security if the IIS virtual derectory that contains the service does not support it?

1 Answers  


Categories