javascript - The anatomy of uploading -


i wondering general consensus uploading moderately large files. have web app, , every time user uploads file (typically larger 5mb), web server tends hang until file upload finished.

the above seems normal, because single upload can take single http request handler. web devs take consideration , either:

a) pay more http handlers

b) use other method overcome using ajax, or other approach

i've heard quite normal web apps have few http request handlers take care of this, cost quite bit more. on other, if cost issue, have suggested trying upload directly web server or storage service (i.e. amazon s3) directly via flash + ajax. latter method takes bit of scripting , bit messy.

my second concern:

by using ajax upload files onto server. still take whole http request handler? i.e. server hang until upload finished?

even flash, still need specify url upload to. url 1 of actions on controller. mean processing still takes place on server side. right far?

i thinking. if were, in other hand, use 1 of upload scripts (plupload, uploadify, swfupload, etc) upload directly amazon s3, processing handled on s3 server instead of local web server. wont hang web app @ all. understanding correctly?

would hear feedback.

for large uploads should use non-blocking, evented servers node.js, twisted on pyhon, anyevent on perl or eventmachine on ruby. using thread-per-connection model expensive long running connections.

it not uncommon node.js users have many simultaneous connections hit operating systems limits while still not using resources - example see this question asked concerned having 30 thousand simultaneous connections , managed reach over 60 thousand connections on single server 4gb of ram.

the point if concerned connections blocking server serving new requests, shouldn't use blocking server in first place.


Comments

Popular posts from this blog

linux - Mailx and Gmail nss config dir -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -