To Rasmus,
I looked into asynch httphandlers, but it would seem that these
are for when your custom processing needs to do asynch work.
ASP.NET just calls you once, then you call ASP.NET back when
you are done with your processing.
From what I have found in many, many web searches for docs,
the first thing that happens when a request (posted file) comes
in is that IIS mapping determines that it should go to the ASP.NET
dll, and then IIS "forwards" the request to whatever BeginRequest
handler is currently associated (built-in or your custom handler).
But, if I understand this process correctly, by the time BeginRequest
has been called, IIS has *already* received (and buffered) the
*entire* request in memory, so even though a custom BeginRequest
handler could read the request in, say, 8000 byte chunks and save
it to a temp file, the stream that it is reading is *already* completely
loaded into IIS memory, so it wouldn't help.
However, as you point out, AspUpload.Net claims that their GigUpload
technology keeps server memory load really low (from their docs, it
looks like the "chunksize" is all that is kept in memory).
So either they are only being *partially* truthful in their marketing
(ASP.NET only uses, say, 8k, but IIS uses the full file size), or I am
missing something.
I know that the interception of an incoming request "as it comes in"
can be done in an ISAPI extension or ISAPI filter, but everything
that I have read states that by the time *any* ASP.NET code sees
the request, IIS has already received the *entire* request.
Any Microsoft folks want to clarify this for me?
Given all that, I really don't know how AspUpload.Net does it without
using a client side control or a real (unmanaged) custom ISAPI filter.
There is one other way to make this work. If you can count on the
browser being Internet Explorer, you can use an ADO objects (the
XMLHttp and Stream objects) along with client-side javascript to
post the upload in small chunks. The problem with this is that the
security settings for Internet Explorer have to be relaxed to allow
reading of local files, and I'm pretty sure that most people won't
want to do this...
J B. Podolak