Bug 817170

Summary: [REST API] Valid gear_profile options should be listed on domains endpoint
Product: OKD Reporter: Clayton Coleman <ccoleman>
Component: PodAssignee: Krishna Raman <kraman>
Status: CLOSED CURRENTRELEASE QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 1.xCC: mfisher, mpatel, xtian
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-05-14 17:22:50 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Clayton Coleman 2012-04-27 22:00:12 UTC
The ADD_APPLICATION link on broker/rest/domains lists "small", "micro", "medium", "large", "exlarge", "jumbo".  For most users only one or two of these are valid.  The client (site in this case) needs to know which are valid.

Either a) implement a separate call that returns how many gears of each type the user can create or b) limit valid_options according to the current user's VIP status / role from ARIA.

Note: When we implement billing, different plans will allow different gear sizes and possibly allow a certain number of free gears.  Suggest we plan for that when fixing this issue.

Will block UI showing gear size option.

Comment 1 Xiaoli Tian 2012-05-03 09:20:41 UTC
Checked this on devenv_1752, it's still the same as before.
             <default-value>small</default-value>
              <name>gear_profile</name>
              <description>The size of the gear</description>
              <valid-options>
                <valid-option>small</valid-option>
                <valid-option>micro</valid-option>
                <valid-option>medium</valid-option>
                <valid-option>large</valid-option>
                <valid-option>exlarge</valid-option>
                <valid-option>jumbo</valid-option>
              </valid-options>
              <type>string</type>
            </optional-param>
          </optional-params>

These components are still the same with 7 days ago
ruby-stickshift-common-0.9.1-1.git.0.8e424a8.el6.noarch
stickshift-abstract-0.10.2-1.git.0.9b78051.el6.noarch
rubygem-stickshift-common-0.9.1-1.git.0.8e424a8.el6.noarch

The change is not built in devenv_1751, need new packages to include this change.

Comment 2 Xiaoli Tian 2012-05-07 06:41:14 UTC
Tested this on devenv_1757, it only shows small and medium now.

#curl  -k -H "Accept: application/xml" --user "xtian+test5:123456"  https://ec2-23-21-38-176.compute-1.amazonaws.com/broker/rest/domains/domx017/   -X GET


  <optional-param>
              <description>The size of the gear</description>
              <name>gear_profile</name>
              <valid-options>
                <valid-option>small</valid-option>
                <valid-option>medium</valid-option>
              </valid-options>
              <type>string</type>
              <default-value>small</default-value>
            </optional-param>
          </optional-params>