Can uploads be too fast?

349 views Asked by At

I'm not sure if this is the right place to ask this, but I'll do it anyway.

I have developed an uploader for the Umbraco CMS that lets people upload a queue of files in one go. This uses some simple flash app that just calls a .NET ashx to upload the files one at a time. When one is done, the next one starts.

Recently I've had a user hit a problem where 1 or 2 uploads will go up fine, but then the rest fail. This happens for himself and a client of his. After some debugging, he thinks he's found the problem, but it seems weird so was wondering if anyone else has had this problem?

Both him and his client are on a fibre optic broadband connection so have got really fast upload speeds. When it was tested on a lesser speed broadband connection, all the files were uploaded no problem. According to one of his developer friends, apparently they had come across it before and had to put a slight delay in the upload script to make it work.

Does this sound possible? Had anyone else hit this problem? Is there a known workaround to prevent the uploads from failing?

2

There are 2 answers

0
Jaybest On

I have not struck this precise problem before, but I have done a lot of diagnosis of DSL and broadband troubleshooting before, so will do my best to answer this.

There are 2 possible causes for this particular symptom, both generally outside of your network control (I would have thought).

1) Packet loss Of course where some links receive a very high volume of traffic then they can chose to just dump a lot of data (eg all that is over that link maximum set size), but TCP/IP should be controlling that, and also expecting that sort of thing to drop from time to time, so this seems less likely.

2) The receiving server May have some HTTP bottlenecks into that server or even the receiving server CPU / RAM etc, may be at capacity.

From a troubleshooting perspective, even if these symptoms shouldn't (in theory) exist, the fact that they do, and you have a specific

Next steps if you really need to understand how it is all working might be to get some sort of packet sniffer (like WireShark) to try to work out at a packet level what exactly is happening.

Also Socket programming can often program directly to the TCP/IP sockets, so you would be processing at the lower network layers, and seeing the responses and timeouts etc.

Also if you control the receiving server, then you can do the same from that end, or at least review the error logs to see what is getting thrown up as a problem.

A really basic method could be to send a pathping to the receiving server if that is possible, and that might highlight slow nodes getting the server, or packet loss between your local machine and the end server.

The upshot? Put in a slow down function in the upload code, and that should at least make the code work.

Get in touch if you need any analysis of the WireShark stuff.

0
Greg Gorman On

I have run into a similar problem with an MVC2 website using Flash uploader and Firefox. The servers were load balanced with a Big-IP load balancer. What we found out in debugging this is that Flash, in Firefox, did not send the session ID on continuation requests and the load balancer would send continuation requests off to another server. Because the user had no session on the new server, the request failed.

If a file could be sent in one chunk, it would upload fine. If it required a second chunk, it failed. Because of this the upload would fail after an undetermined number of files being uploaded.

To fix it, I wrote a Silverlight uploader.