The fastest speed is that non-WCF named pipelines on the local machine have 113 MB/S
The fastest speed for local network machines to transfer files is to use TCP binding of WCF, with a speed of 70 ~ 120 MB/S
Test speed comparison:
|
Local Data Transfer |
Mutual transmission of LAN machines |
HTTP binding for WCF |
104 ~ 116 Mbit/s buffer mode (0.21 Mbit/s for 25 Mbit/s ~ 0.23 seconds) 40 ~ 45 Mb/s stream mode (0.5 Mbit/s for 25 Mbit/s ~ 0.6 seconds) |
50 ~ 60 Mb/s buffer Mode 7 ~ 10 Mb/s stream mode |
TCP binding of WCF |
290 ~ 370 Mbit/s buffer mode (0.07 s for 25 MB) (The name pipeline of WCF only needs 0.07 S) 60 ~ 70 MB/S stream mode |
70 ~ 120 Mbit/s buffer mode (0.20 Mbit/s for 25 Mbit/s ~ 0.37 seconds) 2 ~ 3 Mb/s stream mode |
Non-WCF named Pipeline |
113 MB/S |
10 Mb/s |
The cache size used in the buffer mode is greater than the file size (that is, all files are put into the memory first). This is a way to exchange resources for speed. In actual use, it cannot consume too many resources.
The buffer layer is used for file write operations.
I hope you can communicate with others.
During the test, the buffer size of the read method is 15000. It is found that the buffer speed is too slow. To a certain extent, the data cannot be received and will be terminated in advance.
Test TCP and find that each read has a rule:
First obtain 255,
Second 4089,
Third 6,
Fourth and later 4089
Is this the legendary three-way handshake?
Test HTTP and find that each read operation is 4096