The following are the zookeeper devices on ASP. NET.
1. uploadframehelper provides the getpreviouspage function to obtain cross-page PostBack
As follows:
| <% @ Webhandler Language = "C #" class = "handler" %>
Using system;
Using system. Web;
Using system. reflection;
Using system. Security. permissions;
Using system. IO;
Using system. Web. UI;
Public class handler: ihttphandler {
Public void processrequest (httpcontext context ){
If (uploadframehelper. handleupload ())
{
// The stored statement is stored here.
// Ie:
// Context. Request. Files [0]. saveas (@ "C:/temp1/upload. XXX ");
Page P = uploadframehelper. getpreviouspage ();
System. Web. UI. webcontrols. fileupload FL = (system. Web. UI. webcontrols. fileupload) p. findcontrol ("fileupload1 ");
Fl. saveas (@ "C:/uploadfile" + FL. filename );
Context. response. Write (context. Request. Files [0]. filename );
}
}
Public bool isreusable {
Get {
Return false;
}
}
} |
2. In fact, this mechanism is not limited to the setting of maxrequestlength,
The limit is derived from the program running below.
Hackupload. CS
..........
Public bool load ()
{
If (_ context. Request. contentlength <getmaxrequestsize ())
{
.......... |
If you remove this program, there will be no restrictions on the above cases. I guess it will be limited only to executiontimeout and
Io, probably 2 GB or 4 GB.
3. ASP. NET runtime memory consumption. In the memory, ASP. NET runtime first exists in the memory,
This means that there are a large number of cases above, and many people will use IIS to consume a lot of memory.
From the processing mechanism of ASP. NET runtime, I think there will be a way to solve this problem, but I have to wait for a while to have a good look.