Since the service is controlled by a GUI, the "UseSynchronizationContext" attribute was needed to solve the problem:

[ServiceBehavior(InstanceContextMode=InstanceContextMode.PerCall,ConcurrencyMode=ConcurrencyMode.Multiple,UseSynchronizationContext=false)]


现在开发很多WCf程序已经不托管在IIS下,而是自托管了,所以在客户访问服务时,如果不进行如上设置 ,无法实现真正多的多线程,造成访问排队。

 

相关文章:

  • 2022-12-23
  • 2021-12-22
  • 2022-12-23
  • 2021-06-05
  • 2022-01-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-12-18
  • 2022-12-23
  • 2021-07-28
  • 2021-07-09
相关资源
相似解决方案