title: PerCall InstanceContextMode behaviour of WCF service
body: <p>I have a WCF service, exposing a ServiceContract with basicHttpBinding, so from my understanding <strong>InstanceContextMode</strong> will be set to PerCall (as basicHttpBinding doesn't support sessions) and ConcurrenyMode will be set to Single. </p>
  
  <p>The client of this WCF is a windows service, which invokes 4 different operations on the service at the same time, within the service we have used a singleton class and there are few Static variables. We have been facing a problem where in a wrong value is getting passed to some of the DB Stored Procedures. </p>
  
  <p>With PerCall InstanceContextMode and Single concurrency mode, i understand a new service instacne in created for every call and hence i am thinking that even though there are some singleton classes (we have not made it thread safe) in the service implementation and static variables all the objects  will be destroyed, but we have observed running a SQL profiler that on old value is getting passed the DB.</p>
  
  <p>We have written our WCF service code in a kind of 3-tier architecture, i mean ServiceClass, BusinessLogicLayer and DataAccessLayer, with PerCall set as instanceContextMode when we say the service instance is destroyed after the client request is finished, does it mean we destroy all the object in ServiceClass,BusinessLogicLayer and DataAccessLayer? </p>
  
  <p>Pls help me understand what could be going wrong  </p>