Bug 1020072

Summary: listing cartridges in an app is not backward compatible.
Product: OpenShift Online Reporter: Peter Ruan <pruan>
Component: MasterAssignee: Lili Nader <lnader>
Status: CLOSED CURRENTRELEASE QA Contact: libra bugs <libra-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 2.xCC: ffranz, jhou, mfisher, xtian, zzhao
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-24 03:24:42 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 Peter Ruan 2013-10-17 00:06:41 UTC
Description of problem:
listing cartridges in an app is not backward compatible.  I get a 404 when trying to use the old url format

Old URL has the format:
https://<server>/broker/rest/domains/<domain_name>/applications/<app_name>/cartridges

New format:
https://<server>/broker/rest/application/<app_id>/cartridges


Version-Release number of selected component (if applicable):
DEVENV/PROD/

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Xiaoli Tian 2013-10-17 10:18:37 UTC
This may break JBoss Tools

Comment 2 Xiaoli Tian 2013-10-17 10:40:36 UTC
(In reply to xiaoli from comment #1)
> This may break JBoss Tools

Ignore comment 1, confirmed JBoss tools still work well against current STG at least while adding cartridge

Comment 3 Fabiano Franz 2013-10-18 18:56:40 UTC
This is known and the desired behavior, a few REST API links changed in version 1.6. We suggest the API clients always specify the API version being used through the Accept header, like in:
"Accept: application/json; version=1.5"

Comment 4 Peter Ruan 2013-10-18 19:55:31 UTC
Fabiano:
  The bug was referring to changes to the URL within the same API version (1.6).  Prior to sprint 34, the old links works.  The membership US caused the a lot of the REST URLs to be different but according to Clayton, the old links should still work.  Reopening this bug.

Comment 6 Jianwei Hou 2013-10-22 07:22:20 UTC
This bug is fixed with above PR, will mark as verified once it's merged into master

Comment 7 zhaozhanqi 2013-10-22 10:35:05 UTC
Tested this bug on devenv_3928, it has been fixed.

Both old format and new format are work well.

Old format:

https://ec2-54-224-181-209.compute-1.amazonaws.com/broker/rest/domains/zqd/applications/zqphp/cartridges

New format:
https://ec2-54-224-181-209.compute-1.amazonaws.com/broker/rest/domain/zqd/application/zqphp/cartridges