Bug 803691 - Get "502 Proxy Error" while scaling up a scalable app frequently
Summary: Get "502 Proxy Error" while scaling up a scalable app frequently
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: OKD
Classification: Red Hat
Component: Pod
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Rajat Chopra
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-03-15 12:35 UTC by jizhao
Modified: 2015-05-15 01:48 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-03-16 01:57:25 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description jizhao 2012-03-15 12:35:22 UTC
Description of problem:
Create a scalable app and scale it up frequently. Sometimes the output says "502 Proxy Error"

Version-Release number of selected component (if applicable):
rhc-cartridge-haproxy-1.4-0.6.7-1.el6_2.noarch
rhc-server-common-0.87.1-1.el6_2.noarch
rubygem-rest-client-1.6.1-2.el6.noarch


How reproducible:
Sometimes

Steps to Reproduce:
1.Create a scalable app
$ curl -k -H "Accept: application/xml" --user "jizhao+1:pass"  https://ec2-184-73-49-254.compute-1.amazonaws.com/broker/rest/domains/jizhao1/applications -X POST -d name=app3 -d cartridge=php-5.3 -d scale=true
2.Write a script to scale up the app frequently
<--------------python code----------------->
#!/usr/bin/env python
import subprocess

for i in range(0,20):
    subprocess.call('curl -k -H "Accept: application/xml" --user "jizhao+1:redhat"  https://ec2-184-73-49-254.compute-1.amazonaws.com/broker/rest/domains/jizhao1/applications/app3/events -X POST -d event=scale-up', shell=True)
<------------------------------------------>
3.
  
Actual results:
The app seems to be scaled up successfully, but sometimes get error message:
<------------output---------------->
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>502 Proxy Error</title>
</head><body>
<h1>Proxy Error</h1>
<p>The proxy server received an invalid
response from an upstream server.<br />
The proxy server could not handle the request <em><a href="/broker/rest/domains/jizhao1/applications/app3/events">POST&nbsp;/broker/rest/domains/jizhao1/applications/app3/events</a></em>.<p>
Reason: <strong>Error reading from remote server</strong></p></p>
<hr>
<address>Apache/2.2.15 (Red Hat) Server at ec2-184-73-49-254.compute-1.amazonaws.com Port 443</address>
</body></html>
<----------------------------------->

Expected results:
There shouldn't be any error message.

Additional info:

Comment 1 Rajat Chopra 2012-03-15 22:02:12 UTC
Timeout. 

We have a time out on the requests if they take longer than a minute.

And in today's unoptimized code, the time to scale-up is a function of number of existing gears. This does not mean that the scale-up does not happen, just that the response to client is timed out.

User Story exists to fix this problem. - US2068 
(https://rally1.rallydev.com/#/4670516379d/detail/userstory/5694611186)


Please close this bug as NOTABUG as this is being tracked in the above user story.

Comment 2 jizhao 2012-03-16 01:57:25 UTC
(In reply to comment #1)
> Timeout. 
> 
> We have a time out on the requests if they take longer than a minute.
> 
> And in today's unoptimized code, the time to scale-up is a function of number
> of existing gears. This does not mean that the scale-up does not happen, just
> that the response to client is timed out.
> 
> User Story exists to fix this problem. - US2068 
> (https://rally1.rallydev.com/#/4670516379d/detail/userstory/5694611186)
> 
> 
> Please close this bug as NOTABUG as this is being tracked in the above user
> story.

Close this bug according to comment 1.


Note You need to log in before you can comment on or make changes to this bug.