繁体   English   中英

为什么wsHttpBinding不支持流媒体?

[英]Why doesn't wsHttpBinding support streaming?

为什么wsHttpBinding不支持流媒体?

编辑:为了测试我对netTcpBinding的评论,我尝试了下面的代码,它给出了运行时错误:

<netTcpBinding >
        <binding name="myBinding"  transferMode="Streamed">          
          <reliableSession enabled="true"/>
        </binding>
</netTcpBinding>

运行时异常:

Unhandled Exception: System.InvalidOperationException: Transfer mode Streamed is
 not supported by ReliableSessionBindingElement.
   at System.ServiceModel.Channels.ReliableSessionBindingElement.VerifyTransport
Mode(BindingContext context)

如果删除了<reliableSession enabled="true"/> ,则代码可以正常工作。

由于可靠的消息传递协议(WS-RM),WsHttpBinding不支持流式传输,这要求消息在任一端缓冲。

如前所述这里 ...更多信息WS-RM

也有另一篇文章在这里它提供了能够,为什么上面流相对于推理...

这是因为WS-RM需要将签名/校验和作为统一等应用于整个消息; 当流传输模式时,这是不可能的,只有缓冲的transferMode ...

此外, netTcpBinding实际上使用WS-RM来实现可靠性。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM