Bug 881430

Summary: [rhc][error-handling] "rhc server" not robust to server version
Product: OKD Reporter: Luke Meyer <lmeyer>
Component: ocAssignee: Clayton Coleman <ccoleman>
Status: CLOSED CURRENTRELEASE QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 2.xCC: dmcphers, jinzhang
Target Milestone: ---Keywords: FutureFeature
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-14 00:43:11 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 Luke Meyer 2012-11-28 21:50:32 UTC
Description of problem:
New rhc server command doesn't respond well if run against an older server.

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


Steps to Reproduce:
1. Set up an OpenShift Enterprise installation
2. run rhc server against it
  
Actual results:
[demo1126@lmeyer-client ~]$ LIBRA_SERVER=broker rhc server
/usr/lib/ruby/gems/1.8/gems/rest-client-1.6.1/lib/restclient/abstract_response.rb:48:in `return!': 404 Resource Not Found (RestClient::ResourceNotFound)
        from /usr/lib/ruby/gems/1.8/gems/rest-client-1.6.1/lib/restclient/request.rb:220:in `process_result'
        from /usr/lib/ruby/gems/1.8/gems/rest-client-1.6.1/lib/restclient/request.rb:169:in `transmit'
[...]

Expected results:
A coherent error message about this server not supporting this functionality. 

Additional info:
It appears to be hitting /app/status/status.json which... I'm not even sure what is supposed to supply that, but nothing does in OSE so it's a 404.

Comment 1 Clayton Coleman 2012-12-03 05:58:57 UTC
The status site, which is openshift online only.  Fixed in my debt branch - it will display the api version on other servers.

smarterclayton/help_refactor_and_apps_command

Comment 2 manoj 2012-12-05 19:16:33 UTC
US3117

Comment 3 Clayton Coleman 2013-01-02 19:35:23 UTC
Was fixed and delivered.

Comment 4 joycezhang 2013-01-04 07:44:33 UTC
It's displayed api version with fork_ami_us3117_refactor_help_and_cleanup_with_bug_fixes_327  as below:

# rhc server
Connected to localhost
Login to localhost: 
Password: 
Using API version 1.3