简体   繁体   English

从wcf绑定transferMode从“Buffered”更改为“Streamed”是否被认为是客户端的重大变化?

[英]Is changing from wcf binding transferMode from “Buffered” to “Streamed” considered a breaking change for the client?

I have a WCF service endpoint that serves binary documents through a stream. 我有一个WCF服务端点,通过流提供二进制文档。 The endpoint looks something like this: 端点看起来像这样:

public Stream GetFile(int fileId){
...
}

The basicHttpBinding for this service endpoint is configured erroneously to use TransferMode="Buffered". 此服务端点的basicHttpBinding错误地配置为使用TransferMode =“Buffered”。 The service endpoint is currently used by integrating parties outside my control. 服务端点当前由我控制之外的各方使用。 Due to the memory consumption issues with buffered transfermode I want to change this to TransferMode="Streamed". 由于缓冲传输模式的内存消耗问题,我想将其更改为TransferMode =“Streamed”。

Can I safely do this change on the service binding configuration and expect that this will not break anything for any integrating parties? 我是否可以安全地对服务绑定配置进行此更改并期望这不会破坏任何集成方的任何内容?

To the best of my knowledge, WCF streamed mode transfer is opt-in at the client, meaning that even if you change it at the server, unless the client changes their end as well they'll still receive the stream in its entirety before serving it as a buffered chunk of data. 据我所知,WCF流模式传输是在客户端选择加入,这意味着即使您在服务器上更改它,除非客户端改变其结束,否则他们仍然会在服务之前完整地接收流它作为一个缓冲的数据块。 In other words, it should be transparent to your clients, but will enable them to opt-in to a streamed response. 换句话说,它应该对您的客户端透明,但会使他们选择加入流式响应。

Official Microsoft documentation on the matter confirms it is opt-in and does NOT affect functionality meaning it should not be a breaking change. 关于此事的Microsoft官方文档证实它是选择加入并且不影响功能,这意味着它不应该是一个重大变化。

"You can turn on streaming for requests and replies or for both directions independently at either side of the communicating parties without affecting functionality. However, you should always assume that the transferred data size is so significant that enabling streaming is justified on both endpoints of a communication link. For cross-platform communication where one of the endpoints is not implemented with WCF, the ability to use streaming depends on the platform's streaming capabilities." “您可以在通信方的任何一方独立地为请求和回复或两个方向打开流式传输,而不会影响功能。但是,您应该始终假设传输的数据量非常大,以至于在两个端点上启用流式传输是合理的。通信链路。对于其中一个端点没有使用WCF实现的跨平台通信,使用流的能力取决于平台的流媒体功能。“

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

相关问题 将wcf传输程序从缓冲更改为流式传输 - Change a wcf transfer program from buffered to streamed WCF HttpTransport:流式传输与缓冲的TransferMode - WCF HttpTransport: streamed vs buffered TransferMode WCF:通过netTcpBinding通过TransferMode = Streamed将文件传输到服务器时,对客户端的响应延迟 - WCF: response to client delayed when transferring file to server with TransferMode=Streamed over netTcpBinding 具有TransferMode = Streamed的WCF REST客户端-记录整个(“原始”)http请求/响应 - WCF REST client with TransferMode=Streamed - logging entire (“raw”) http requests/responses 无法通过 WCF 从客户端向服务器发送流数据 - Can't send streamed data from client to server via WCF 使用basichttpBinding和流的transfermode的WCF中出现错误请求 - error Bad Request in WCF using basichttpBinding with transfermode of streamed 如何将自定义对象序列化为流(WCF HttpBinding-TransferMode =流式) - How to seralize custom objects into stream (WCF HttpBinding - TransferMode = Streamed) TransferMode = Streamed时发生TimeoutException - TimeoutException when TransferMode=Streamed 无法通过nettcp绑定上传大文件,并且transfermode =“ buffered” - Unable to upload large file via nettcp binding and transfermode=“buffered” NetTcpBinding()与TransferMode.Streamed - NetTcpBinding() with TransferMode.Streamed
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM