Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 329696

Summary: CDO downloads page calls the webserver, loops and consumes many resources
Product: [Modeling] EMF Reporter: Denis Roy <denis.roy>
Component: cdo.docsAssignee: Project Inbox <emf.cdo-inbox>
Status: CLOSED FIXED QA Contact:
Severity: critical    
Priority: P3 CC: stepper
Version: 4.0   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
Access log none

Description Denis Roy CLA 2010-11-08 13:13:18 EST
Created attachment 182643 [details]
Access log

On www.eclipse.org, I am seeing frequent exhaustion of available sockets for http clients.  It appears there is something broken with the CDO downloads page.  Since this page calls the webserver itself (instead of opening files locally), each nested call occupies one client 'slot' until all 800 are consumed and never released.

Please:

a) avoid opening "local" URLs such as www.eclipse.org -- this consumes 2x the memory for one page hit

b) test for endless loops in your PHP code


Attached is a very small subset of my Apache log.  The IP address you see is the webserver calling itself.  I'm seeing hits in excess of 30/second.
Comment 1 Denis Roy CLA 2010-11-08 14:42:10 EST
http://www.eclipse.org/cdo/downloads/ seems to be the culprit.  I've commented out this line, since it seems to be the culprit:

# printDownloads("http://www.eclipse.org/modeling/emf/downloads/index.php?project=cdo&showAll=0&showMax=5");
Comment 2 Denis Roy CLA 2010-11-08 14:43:22 EST
Actually, http://www.eclipse.org/modeling/emf/downloads/index.php?project=cdo&showAll=0&showMax=5 seems to redirect to /downloads/cdo/, which is a big part of the problem.
Comment 3 Eike Stepper CLA 2010-11-09 00:32:30 EST
Investigating...
Comment 4 Eike Stepper CLA 2010-11-09 00:39:45 EST
I've found the loop and removed it. Sorry for the hazzle!
Comment 5 Eike Stepper CLA 2010-11-09 00:45:58 EST
Denis, am I right that you've entirely "blanked" the URL http://www.eclipse.org/cdo/downloads/ ? I can not test whether my changes aolve the issue but I'm 100% sure that they do. Please remove your extra filter and try it...
Comment 6 Denis Roy CLA 2010-11-09 09:57:46 EST
I've removed my code and updated from CVS. Looks like it works now, thanks.
Comment 7 Eike Stepper CLA 2011-06-23 04:23:06 EDT
Closing.