HTTP file upload operation takes a long time to complete

xiaoxiao2021-03-06  37

Important: This article contains information about modifying the registry. Before modifying the registry, you must back up the registry and must know how to restore the registry when there is a problem. For information on how to back up, restore, and edit the registry, click the article number below to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows Registry

Symptom When using an HTTP file upload function upload size for a few megabytes of files, uploading will take a long time to complete.

Note: This problem is recorded in the Request for Comment (RFC) 1867 "Form-Based File Upload In Html".

The reason for this problem is that the default Winsock Send buffer size is 8 KB, so Internet Explorer provides data at 8 kb size block area. In a general network, this is equivalent to about 80 kB (Kbp) per second (regardless of the network bandwidth).

For additional information, click the article number below to see the article in the Microsoft Knowledge Base:

214397 Info: Design Issues - Sending Small Data Segments over TCP W / Winsock

Solution To resolve this issue, configure Internet Explorer to increase the send buffer when communicating with Winsock. This can improve network performance when you use the HTTP file upload method. To do this, follow these steps.

Warning: If the registry editor can cause serious problems, these issues may need to reinstall the operating system. Microsoft does not guarantee that you can solve problems due to improper use of registry editors. Use Registry Editor at your own risk.

Start the Registry Editor (regedt32.exe). Find and click the registry key below: HKEY_CURRENT_USER / SOFTWARE / Microsoft / Windows / CurrentVersion / Internet Settings On the Edit menu, click Add Value, then add the following registration value: Numeric Name: SocketsendBufferLength Data Type: REG_DWORD Base: Decang Value data: The desired buffer size (byte) buffer size option: 16 KB buffer = 1638424 KB buffer = 2457632 KB buffer = 3276840 KB buffer = 4096048 KB buffer = 5734464 KB buffer = 65536 exits the registry editor. Be sure to test each value from the 16 KB buffer. When the upload performance becomes acceptable, select the corresponding buffer area.

This behavior is a design.

MORE INFORMATION When you use the procedure described in the Solution section of this article, any WinineTAPI is used.

The HTTPSendRequest function (the program provided by the Microsoft Developer Network (MSDN) Web site will allocate and request the Winsock to send buffers in the definition of the registry key.

related

For additional information on the HttpsendRequest function, please visit the following MSDN Web site:

Http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wininet/wininet/httpsendRequest.asp information about Winsock Send Buffer Behavior, click on the following article number, To view the article in Microsoft Knowledge Base: 214397 Info: Design Issues - Sending Data Segments over TCP W / Winsock

The information in this article applies to:

Microsoft Internet Explorer version 6 for Windows XP Microsoft Internet Explorer version 6 for Windows 2000 Microsoft Internet Explorer version 6 for Windows NT 4.0 Microsoft Internet Explorer version 6 for Windows Millennium Edition Microsoft Internet Explorer version 6 for Windows 98 Second Edition Microsoft Internet Explorer 5.5 for Windows 2000 Microsoft Internet Explorer 5.5 for Windows NT 4.0 Microsoft Internet Explorer 5.5 for Windows Millennium Edition Microsoft Internet Explorer 5.5 for Windows 98 Second Edition Microsoft Internet Explorer 5.01 for Windows 2000

转载请注明原文地址:https://www.9cbs.com/read-71714.html

New Post(0)