How to increase the performance of the WCF Service, simply change the service behavior to optimize the performance of the application.
here is the snippet
[ServiceBehavior(InstanceContextMode=InstanceContextMode.PerSession,
ConcurrencyMode=ConcurrencyMode.Multiple)]
update your service behavior with above snippet,
Explanation:- here we are adding InstanceContextMode=InstanceContextMode.PerSession it mean that it will create object of service per session or in other words one object for each session, and second one we added ConcurrencyMode=ConcurrencyMode.Multiple ConcurrencyMode mean how many request we can process at once change it to multiple mean we can process multiple request at a time.
No comments:
Post a Comment