Okay, I've done my detective work, and don't have any answers.  I'm  
about to upgrade from Webware 0.8.1 to 0.9.2, so I'll see if that  
mysteriously fixes things.

In the meantime, for those interested, here are the details on the  
behavior / the environments / etc:

  - On my dev server, large file uploads stall and lock up a thread.   
On production, they work fine.

The thread which is handling the upload freezes -- the rest of the  
app is responsive, but that thread gets totally stuck (I had said  
yesterday that the entire app freezes, but I was wrong).  To get the  
system to shutdown, I have to kill -9 it (a normal restart hangs up  
in the "ThreadedAppServer: shutting down" stage).

  - I'm not sure where 'large' kicks in, but around a couple hundred  
K, I think.  I definitely see it for > 1 M files.

  - Environments:

Dev:
  - Mac OS X 10.4.3
  - Apache 2
  - Webware 0.8.1
  - mod_webkit (from that 0.8.1 version)
  - python 2.3.5
  - launching via WebKit/AppServer start (which runs  
ThreadedAppServer, I believe)


Production:
  - Linux (2.4.21, sayeth uname -a)
  - Apache 2
  - Webware 0.8.1
  - mod_webkit (could be from a more recent webware build -- 0.9.x,  
possibly)
  - python 2.3.5
  - launching via WebKit/AppServer start


I drilled down into the guts of the cgi module and  
ThreadedAppServer.  The place where it's locking up is in a loop in  
cgi.FileStorage.read_lines_to_outerboundary, in a call to  
self.fp.readline() (where fp is a file-like object derived from the  
socket carrying data from Apache).

It makes a long series of successful reads from that socket, and  
then, after getting about 130K of data, it just hangs up.

After 5 minutes, the browser cancels the request.  At that point, the  
hung fp.readline() call returns a little more data, and the whole  
thing completes (in an error state, but the thread is no longer hung).

That's what I've got...

I'll let you know if the 0.9.2 move helps or not.
-Dan


On Sep 12, 2006, at 4:12 PM, Chuck Esterbrook wrote:

> On 9/12/06, Dan Milstein <[EMAIL PROTECTED]> wrote:
>> I don't have any kind of answer, but I've had a similar thing come
>> up, so I'll pass it on, in case it helps narrow the focus:
>>
>>   - In my dev environment (Webware 0.8.1 / Apache 2 / Mac OS X 10.4),
>> when I do large file uploads, it freezes the entire webware process
>>
>> Works fine in the production environment, so I've been lazy about
>> tracking it down, but it's a particularly nasty freeze.  I have to
>> kill -9 the process to get it to die.  Which does have the flavor of
>> some sort of GIL issue.
>
> Can you tell us what's different between your production and dev
> environment? That would include how the process is launched as well.
> And is there a difference in what modules get imported?
>
> Also, even if you tapped into the cgi module, would you really be able
> to give the user a progress bar? It seems that their window would be
> tied up by the upload task being performed by the browser.
>
> Gary, I'm sorry I don't have an answer. I guess I've been lucky enough
> not to have this problem on production or development.
>
> -Chuck
>
> ---------------------------------------------------------------------- 
> ---
> Using Tomcat but need to do more? Need to support web services,  
> security?
> Get stuff done quickly with pre-integrated technology to make your  
> job easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache  
> Geronimo
> http://sel.as-us.falkag.net/sel? 
> cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> Webware-discuss mailing list
> Webware-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/webware-discuss


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Webware-discuss mailing list
Webware-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/webware-discuss

Reply via email to