The stream transmission mode of webhttpbinding makes my head big.

Source: Internet
Author: User
Webhttpbinding supports two stream transmission and cache modes. to download files, you must select the stream transmission mode. Otherwise, all files must be loaded into the memory before being sent out, it not only occupies a large amount of memory overhead, but also affects the speed of sending responses. The problem is that the transfer-encoding: chunked method is automatically used in streaming. In this way, the length of the client file is not notified. Even if the message header is set on my server, the client cannot get the length, as a result, the client assumes that my server does not support resumable data transfer, or even multi-threaded data download. Unless you develop a download software, the traditional download software is not supported, but nettransport can still try to send the resume command without knowing whether it can be resumed. This is the most user-friendly software.

There is only one way to consider it. It is to transform the cache mode of webhttpbinding. The cache mode is a traditional HTTP response, and can be set for all kinds of HTTP headers. resumable data transfer is a natural process, multi-thread transmission can be used. The problem to be solved is that the message is written, and the message cannot be written to the cache. Instead, the message is obtained from the stream in real time (if the returned Stream object is a stream object ).

The research direction is determined. Let's see if a webhttpbinding similar binding class can be successfully customized. To be continued ......

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.