Description of problem: Call RESTAPI to list all regions, the value of 'default' of the default region is shown as 'false' when it should be 'true'. Version-Release number of selected component (if applicable): devenv_4932 How reproducible: Always Steps to Reproduce: 1. Create 2 regions with oo-admin-ctl-region 2. Set one region as default in broker-dev.conf, restart broker service [root@ip-10-231-164-224 ~]# tail -n 1 /etc/openshift/broker-dev.conf DEFAULT_REGION_ID="region_1" 3. Call RESTAPI to list all regions curl -s -k -H 'Content-Type: Application/json' https://ec2-54-196-70-231.compute-1.amazonaws.com/broker/rest/regions -X GET Actual results: After step 3: The values of 'default' of all regions are 'false', as a consequence, the end user has no way to know which one is default "data": [ { "default": false, "id": "53b3a8bf8fbc0995b0000001", "name": "region_1", "zones": [ { "_id": "53b3a9591c79cb4e2b000001", "_type": null, "created_at": "2014-07-02T06:40:25Z", "name": "zone_1", "updated_at": "2014-07-02T06:40:25Z" } ] }, { "default": false, "id": "53b3ab78924d888611000001", "name": "region_2", "zones": [ ] } ], Expected results: region_1 is the default region, so it should have: 'default': true Additional info:
Fixed in https://github.com/openshift/li/pull/2733
Commit pushed to master at https://github.com/openshift/li https://github.com/openshift/li/commit/6f3b7f26ecfaaf31a8d48733847ea4d9d5c2eb0f Bug 1115274 - Fix 'default' field in /regions REST api
Commit pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/0598d3648d0e33052970a83a229296f9cb6396ab Bug 1115274 - Fix 'default' field in /regions REST api
Verified on devenv_4940, the default region can be shown properly { "api_version": 1.7, "data": [ { "default": true, "id": "53ba3d321b5cd03c51000001", "name": "region_1", "zones": [ ] }, { "default": false, "id": "53ba3d49e3afb83cfc000001", "name": "region_2", "zones": [ ] } ], "messages": [ { "exit_code": 0, "field": null, "index": null, "severity": "info", "text": "Listing 2 region(s)" } ], "status": "ok", "supported_api_versions": [ 1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7 ], "type": "regions", "version": "1.7" }