异常提示:
System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.
Parameter name: requestMsg


场景:
1.用IIS作宿主。
2.使用BinaryFomatter。
3.客户端订阅服务器端事件后,服务器端激活事件时产生。

解决措施:

在配置文件中将单通道改为双向通道
原配置文件:

.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.<system.runtime.remoting>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.  
<application>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
<service>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
</service>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
<channels>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.      
<channel ref="http">
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.        
<serverProviders>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.          
<provider ref="binary" typeFilterLevel="Full"/>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.        
</serverProviders>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.      
</channel>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
</channels>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.  
</application>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.
</system.runtime.remoting>

新配置文件:
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.<system.runtime.remoting>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.  
<application>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
<service>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
</service>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
<channels>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.      
<channel ref="http">
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.        
<serverProviders>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.          
<provider ref="binary" typeFilterLevel="Full"/>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.        
</serverProviders>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.        
<clientProviders>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.          
<provider ref="binary"></provider>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.        
</clientProviders>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.      
</channel>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.    
</channels>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.  
</application>
.Net Remoting 排错笔记:System.ArgumentNullException: No message was deserialized prior to calling the DispatchChannelSink.
</system.runtime.remoting>

测试通过。

相关文章:

  • 2021-07-18
  • 2021-06-27
  • 2021-07-14
  • 2021-05-16
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-24
猜你喜欢
  • 2021-08-03
  • 2022-12-23
  • 2021-11-08
  • 2021-09-30
  • 2021-07-26
  • 2022-12-23
  • 2021-05-22
相关资源
相似解决方案