Bug 812802 - cannot estimate correct gear consumption for scalable app
cannot estimate correct gear consumption for scalable app
Status: CLOSED CURRENTRELEASE
Product: OpenShift Origin
Classification: Red Hat
Component: Pod (Show other bugs)
1.x
Unspecified Unspecified
low Severity low
: ---
: ---
Assigned To: Ravi Sankar
libra bugs
: Regression, Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-04-16 05:32 EDT by Meng Bo
Modified: 2012-07-13 19:43 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-07-13 19:43:32 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Meng Bo 2012-04-16 05:32:50 EDT
Description of problem:
estimate the gear consumption of scalable app, will not get the correct gear number.

Version-Release number of selected component (if applicable):
stage-2.0.9

How reproducible:
always

Steps to Reproduce:
1.curl  -k -X GET -H 'Accept: application/xml' --user <user>:<password> -d descriptor="Name: aa\nRequires: \n- php-5.3\nScalable: true\n" https://<instance_ip>/broker/rest/estimates/application
2.
3.
  
Actual results:
there is only one gear can be recognized, php-5.3

Expected results:
it should have two gears in total. php-5.3 and haproxy-1.4


Additional info:
Comment 1 Ravi Sankar 2012-07-03 20:00:08 EDT
'Scalable' param is NOT part of the application descriptor. Current code ONLY estimates non-scalable apps and eventually we want to make this work for scalable apps as well.
Note: Unknown params to application descriptor will be ignored. In this case, 'Scalable' param will be ignored.
Cleanup is done in git rev c5abbc5b853.
Comment 2 Rony Gong 2012-07-03 22:48:28 EDT
Verified on devenv_1874
non-scalable:
[root@localhost qnodejs]# curl  -k -X GET -H 'Accept: application/xml' --user qgong@redhat.com:xx -d descriptor="Name: q1ruby19dd\nRequires: \n- ruby-1.9\n  \n- mysql-5.1\n" https://ec2-107-21-180-244.compute-1.amazonaws.com/broker/rest/estimates/application
<?xml version="1.0" encoding="UTF-8"?>
<response>
  <supported-api-versions>
    <supported-api-version>1.0</supported-api-version>
  </supported-api-versions>
  <data>
    <gear>
      <components>
        <component>
          <Name>ruby-1.9</Name>
        </component>
        <component>
          <Name>mysql-5.1</Name>
        </component>
      </components>
    </gear>
  </data>
  <messages/>
  <status>ok</status>
  <type>application_estimates</type>
  <version>1.0</version>
</response>



scalable:
[root@localhost qnodejs]# curl  -k -X GET -H 'Accept: application/xml' --user qgong@redhat.com:xx -d descriptor="Name: qs1ruby19\nRequires: \n- ruby-1.9\n \n- mysql-5.1\nScalable: true\n" https://ec2-107-21-180-244.compute-1.amazonaws.com/broker/rest/estimates/application
<?xml version="1.0" encoding="UTF-8"?>
<response>
  <supported-api-versions>
    <supported-api-version>1.0</supported-api-version>
  </supported-api-versions>
  <data>
    <gear>
      <components>
        <component>
          <Name>mysql-5.1</Name>
        </component>
      </components>
    </gear>
    <gear>
      <components>
        <component>
          <Name>ruby-1.9</Name>
        </component>
      </components>
    </gear>
  </data>
  <messages/>
  <status>ok</status>
  <type>application_estimates</type>
  <version>1.0</version>
</response>

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