Description of problem: When requesting per-gear status from a scaled app, the haproxy cartridge is shown as present in all framework gears, though it is not. Given we can set an app HA and have a >1 subset of the gears have this cartridge, it would be nice if rhc didn't misrepresent this. Steps to Reproduce: 1. rhc app create foos php-5.4 mysql-5.5 -s 2. rhc cartridge scale -a foos php-5.4 --min 5 3. rhc app show -a foos --gears Actual results: ID State Cartridges Size SSH URL ------------------------ ------- ------------------- ----- ------------------------------------------------------------------ 535914dc6892dfc495000007 started haproxy-1.4 php-5.4 small 535914dc6892dfc495000007.com 5359152c6892dfc495000027 started haproxy-1.4 php-5.4 small 5359152c6892dfc495000027.com 5359152c6892dfc495000028 started haproxy-1.4 php-5.4 small 5359152c6892dfc495000028.com 5359152c6892dfc495000029 started haproxy-1.4 php-5.4 small 5359152c6892dfc495000029.com 5359152c6892dfc49500002a started haproxy-1.4 php-5.4 small 5359152c6892dfc49500002a.com 53591af76892dfc49500005b started mysql-5.5 small 53591af76892dfc49500005b.com Expected results: ID State Cartridges Size SSH URL ------------------------ ------- ------------------- ----- ------------------------------------------------------------------ 535914dc6892dfc495000007 started haproxy-1.4 php-5.4 small 535914dc6892dfc495000007.com 5359152c6892dfc495000027 started php-5.4 small 5359152c6892dfc495000027.com 5359152c6892dfc495000028 started php-5.4 small 5359152c6892dfc495000028.com 5359152c6892dfc495000029 started php-5.4 small 5359152c6892dfc495000029.com 5359152c6892dfc49500002a started php-5.4 small 5359152c6892dfc49500002a.com 53591af76892dfc49500005b started mysql-5.5 small 53591af76892dfc49500005b.com Additional info: In this case rhc is basically passing on what it gets from the API, which lists haproxy and php in a single gear group, and all the gears in that gear group in an array, without differentiating which of the gears actually has both cartridges. Perhaps for a sparse cartridge there should be some indicator in the API of which gears actually have it?
Reassigning to check if we can fix this in the broker. The REST API call involved is: /broker/rest/application/<id>/gear-groups
So this API returns gear groups and not gears. Using the above steps to reproduce 2 gear groups are returned: First groups contains one gear and one cartridge. Second groups contains 5 gears and two cartridges (php and haproxy) So the API returns correct information but it is lacking the granularity that the client tools need which is per gear info.
I believe the necessary granularity is actually present if the "include=endpoints" option is added at the gear-groups endpoint. This indicates per-gear which cartridge is present.
Created attachment 916514 [details] response from /application/id/gear_groups?include=endpoints
Verified that include=endpoints will return the additional information required to show which gears have the haproxy cartridge and which gears have only the php cartridge (see attachment). Assigning back to client tools team to make the changes on rhc.
Fixed in https://github.com/openshift/rhc/pull/632
Commit pushed to master at https://github.com/openshift/rhc https://github.com/openshift/rhc/commit/d858baefbad9d0d85ee46fa05a8642d169cad039 Bug 1091071 - properly displays haproxy on app gears
Checked on devenv_5011 with rhc-1.28.3, and the result is as expected result now, so verify this issue.