Bug 967395 - Fail to show cartridges' status via RHC for both web cartridges and add-on cartridges
Fail to show cartridges' status via RHC for both web cartridges and add-on ca...
Status: CLOSED CURRENTRELEASE
Product: OpenShift Online
Classification: Red Hat
Component: Pod (Show other bugs)
2.x
Unspecified Unspecified
medium Severity high
: ---
: ---
Assigned To: Rajat Chopra
libra bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-26 23:12 EDT by Zhe Wang
Modified: 2015-05-14 20:17 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-06-11 00:11:25 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 Zhe Wang 2013-05-26 23:12:38 EDT
Description of problem:
It fails to show cartridges' status for both web cartridges and add-on cartridges via RHC.

Version-Release number of selected component (if applicable):
devenv_3277
rhc-1.9.4


How reproducible:
always

Steps to Reproduce:
1. create an application
2. embed an add-on cartridge (of any type) to this app
3. show the status of both the web cartridge and its add-on cartridge via RHC

Actual results:
The status of those cartridges is empty:

For example,

[zhe@fedora run79]$ rhc cartridge status metrics-0.1 -a rb9
RESULT:
[zhe@fedora run79]$ rhc cartridge status ruby-1.9 -a rb9
RESULT:


Expected results:
It should be successful to show the status of cartridges via RHC.

Additional info:
Comment 1 Zhe Wang 2013-05-28 06:16:08 EDT
Raised the severity of this bug to HIGH, since it blocks auto tests.
Comment 2 Paul Morie 2013-05-28 10:06:07 EDT
It looks like the broker is not making a call to the node for the cartridge status.  From the broker log:

ESC[0;37m2013-05-28 10:03:55.537ESC[0m [ESC[31mERRORESC[0m] undefined method `cartridge_name' for "mock-
0.1":String (pid:2836)
ESC[0;37m2013-05-28 10:03:55.537ESC[0m [ESC[31mERRORESC[0m] #<NoMethodError: undefined method `cartridge
_name' for "mock-0.1":String> (pid:2836)
ESC[0;37m2013-05-28 10:03:55.538ESC[0m [ESC[31mERRORESC[0m] ["/opt/rh/ruby193/root/usr/share/gems/gems/o
penshift-origin-msg-broker-mcollective-1.9.5/lib/openshift/mcollective_application_container_proxy.rb:10
79:in `status'", "/opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-controller-1.9.7/app/models/
gear.rb:109:in `status'", "/opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-controller-1.9.7/ap
p/models/application.rb:831:in `block in component_status'", "/opt/rh/ruby193/root/usr/share/gems/gems/o
penshift-origin-controller-1.9.7/app/models/group_instance.rb:181:in `call'", "/opt/rh/ruby193/root/usr/
share/gems/gems/openshift-origin-controller-1.9.7/app/models/group_instance.rb:181:in `block in run_on_g
ears'", "/opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-controller-1.9.7/app/models/group_ins
tance.rb:179:in `each'", "/opt/rh/ruby193/root/usr/share/gems/gems/openshift-origin-controller-1.9.7/app
/models/group_instance.rb:179:in `run_on_gears'", "/opt/rh/ruby193/root/usr/share/gems/gems/openshift-or
igin-controller-1.9.7/app/models/application.rb:830:in `component_status'"
Comment 3 Paul Morie 2013-05-28 10:17:33 EDT
Changing component to broker.  It looks like the problem is that origin-server/controller/app/models/gear.rb#109 passes the cartridge name to the mcollective proxy, which is expecting the component_instance instead (origin-server/plugins/msg-broker/mcollective/lib/openshift/mcollective_application_container_proxy.rb:1079)
Comment 4 Rajat Chopra 2013-05-28 12:32:22 EDT
Fixed with pull request #2654
Comment 5 Zhe Wang 2013-05-29 01:48:21 EDT
Verified in devenv_3282

Tested a ruby-1.9 app with mysql-5.1 embedded, and the results of showing the cartridges' status were:

[zhe@fedora run80]$ rhc cartridge status mysql-5.1 -a rb9
RESULT:
MySQL is running

[zhe@fedora run80]$ rhc cartridge status ruby-1.9 -a rb9
RESULT:
Application is running

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