Bug 967395 - Fail to show cartridges' status via RHC for both web cartridges and add-on cartridges
Summary: Fail to show cartridges' status via RHC for both web cartridges and add-on ca...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Pod
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
high
Target Milestone: ---
: ---
Assignee: Rajat Chopra
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-05-27 03:12 UTC by Zhe Wang
Modified: 2015-05-15 00:17 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-06-11 04:11:25 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Zhe Wang 2013-05-27 03:12:38 UTC
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 10:16:08 UTC
Raised the severity of this bug to HIGH, since it blocks auto tests.

Comment 2 Paul Morie 2013-05-28 14:06:07 UTC
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 14:17:33 UTC
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 16:32:22 UTC
Fixed with pull request #2654

Comment 5 Zhe Wang 2013-05-29 05:48:21 UTC
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.