WCF: using streaming with Message Contracts

前端 未结 3 1393
[愿得一人]
[愿得一人] 2020-12-07 18:02

I am trying to use the WCF streaming with Message Contracts, because I need additional parameters beside the stream itself.

Basically I am creating a file upload and

3条回答
  •  孤城傲影
    2020-12-07 18:35

    Do you need streaming (i.e. transfer of humonguous data amounts) both on the request and response? Or just on the response (typically: downloading a file or large data set)?

    If you need only on the response, you should try to set the transfermode to "StreamedResponse":

    
        
            
            
        
    
    

    The "Streamed" setting will stream both ways - both the request going to the server, as well as the response from the server, will be streamed. More often than not, that's not the ideal scenario.

    Marc

提交回复
热议问题