Re: Pushing the limit of PHP vs ASP.NET

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: James Macbell (j.NOSPAMmacbell_at_msn.com)
Date: 05/14/04


Date: Fri, 14 May 2004 17:37:55 GMT

I tried putting this in, didn't make a difference. I even tried to turn off
"buffering" in App Option in IIS, same thing.

<%@ Page Language="C#" Buffer="false" %>

I think it is not a performance issue, it is the limitation of ASP.NET
(perhaps there is some configuration in IIS or Registry that I need to
set?). Have you tried to run the code on your server and successfully saved
the 150 MB file to your local HDD? I couldn't....

PHP worked it out without problem, even under Apache for Win32, I am very
impressed. I like both ASP.NET and PHP, don't get me wrong, I am NOT trying
to prove which lang is more superior than the other, I just try to find a
solution to my problem encountered.

James

"bruce barker" <nospam_brubar@safeco.com> wrote in message
news:ORAL1HdOEHA.4036@TK2MSFTNGP12.phx.gbl...
> turn off page buffering to match php performance.
>
> -- bruce (sqlwork.com)
>
>
> "James Macbell" <j.NOSPAMmacbell@msn.com> wrote in message
> news:aI5pc.2223$0qd.1936@twister01.bloor.is.net.cable.rogers.com...
> > I think I have pushed ASP.NET to the limit, I am not sure if I have done
> > anything wrong in the code because I am trying to make 2 pieces of code
> (C#
> > vs PHP) using the same algorithm. Anyways, here is the my test.
> >
> > How: Create a HTML page with 2 hyper links to these files (posted
below).
> > Right click, Save target As.
> > Tested: On my P4 1.6 GHz , 1 GB Ram server, Windows 2000 IIS 5 and
Apache
> > 1.3 for win32, 100 Mbps LAN
> > Sample Size: 150 MB download
> > Result: IIS stopped responding when I tried to download the link to my
> local
> > HDD across the 100 Mbps network, then it poped up window saying "request
> is
> > unavailable". PHP worked without problem at all, I verified the saved
> file
> > was 150 MB on my local HDD.
> >
> > Note:
> > 1. In C# buffer += "x"; is a bit expensive but I have tried
StringBuffer,
> > doesn't matter, it only runs for 1024 times anyways.
> > 2. I also tried to set Response.BufferOutput = false in C#, but the
> download
> > speed was so slow like back in dial-up ages and the HDD was spinning
like
> > crazy.
> >
> > - James
> >
> > ASP.NET code
> > ===============================================
> >
> > <%@ Page Language="C#" %>
> > <%@ Import Namespace="System.IO" %>
> > <script language="C#" runat="server">
> > void Page_Load() {
> > int size= 156105356; // 150 MB data
> > String buffer = "";
> >
> > for (int i=1; i<=1024; i++)
> > buffer += "x";
> >
> > for (int j=1; j<=size/1024; j++)
> > Response.Write(buffer);
> > }
> > </script>
> >
> >
> > PHP code
> > ===============================================
> >
> > <?php
> >
> > $size= 156105356; // 150 MB data
> > $buffer = "";
> >
> > for ($j=1; $j<=1024; $j++)
> > $buffer .= "x";
> >
> > for ($i=1; $i<=($size/1024); $i++)
> > echo $buffer;
> >
> > ?>
> >
> >
>
>



Relevant Pages

  • Re: Pushing the limit of PHP vs ASP.NET
    ... "buffering" in App Option in IIS, ... the 150 MB file to your local HDD? ... PHP worked it out without problem, even under Apache for Win32, I am very ... > turn off page buffering to match php performance. ...
    (alt.php)
  • Re: Pushing the limit of PHP vs ASP.NET
    ... turn off page buffering to match php performance. ... IIS stopped responding when I tried to download the link to my ... > was 150 MB on my local HDD. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Pushing the limit of PHP vs ASP.NET
    ... turn off page buffering to match php performance. ... IIS stopped responding when I tried to download the link to my ... > was 150 MB on my local HDD. ...
    (alt.php)
  • Re: Pushing the limit of PHP vs ASP.NET
    ... IIS stopped responding when I tried to download the link to my local ... PHP worked without problem at all, ... > was 150 MB on my local HDD. ... IIS vs. Apache. ...
    (alt.php)
  • Re: Pushing the limit of PHP vs ASP.NET
    ... IIS stopped responding when I tried to download the link to my local ... PHP worked without problem at all, ... > was 150 MB on my local HDD. ... IIS vs. Apache. ...
    (microsoft.public.dotnet.framework.aspnet)