Thursday, 19 July 2012

WCF Instance Management | Wcf Tutorial | Three ways to do WCF instance management (Per call, Per session and Single)

Hi Friends, in this article I will explain about the Instance Management in WCF.
Instance Management is a set of techniques helping us to bind all client requests to service instances governing which instance handles which request. This is useful to decide scalability, performance, durability, transactions and queued calls.

There are three Instance Management .
1.Per-Call instance mode
2.Per-Session instance mode
3.Singleton Instance mode.

Per-Call instance mode:
Per-Call service allocates and destroys a new Service instance for each client request.
When we configure a WCF service as per call, new service instances are created for every method call you make via a WCF proxy client.

Per-Session instance mode:
Per-Session service allocates a service instance for each client connection.
Very often we need to maintain state between method calls or for a particular session. For those kinds of scenarios, we will need to configure the service per session. In per session, only one instance of a WCF service object is created for a session interaction.

Singleton Instance mode:
Singleton service shares same service instance for all clients across all connection and activation. Often we would like to create one global WCF instance for all WCF clients. To create a single instance of a WCF service, we need to configure the WCF service as Single instance mode.

"If you like my blog or articles, you can appreciate by leaving your comments or Liking my Facebook pageAspdotnet-kishore, following on Google+ Aspdotnet-Kishore, Twitter  on AspdotnetKishore, Linked in Aspdotnet-Kishore, stumbling my posts on stumble upon and subscribing on  RSSfeed Aspdotnet-Kishore for free updates directly to your Email inbox . Watch my blog  for more articles"
"If you like my blog or articles, you can appreciate by leaving your comments or Liking my Facebook page Aspdotnet-kishore, following on Google+ Aspdotnet-Kishore, Twitter on AspdotnetKishore, Linked in Aspdotnet-Kishore, stumbling my posts on stumble upon and subscribing on RSSfeed Aspdotnet-Kishore for free updates directly to your Email inbox . Watch my blog for more articles."

2 comments:

© 2012-2014 Aspdotnet-Kishore.blogspot.com. All Rights Reserved.
The content is copyrighted to Kishore and may not be reproduced on other websites without permission from the owner.