Red Hat Bugzilla – Bug 987317
[fork][origin_broker_25]should not update domain name via 'id' since 'id' field is already changed to 'name' for rest api version 1.6
Last modified: 2015-05-14 20:55:08 EDT
Description of problem:
Since we have change 'id' to 'name' about domain resource, now we invoke rest api version=1.6 to update domain name use 'id': curl -k -H 'Accept: application/xml,version=1.6' --user user:pass https://<instance>/broker/rest/domains/zqd -d id=newzqd -X PUT, it still can be updated successfully.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. create one domain use rest api
2. update domain user rest api version=1.6
curl -k -H 'Accept: application/xml,version=1.6' --user user:pass https://<instance>/broker/rest/domains/zqd -d id=newzqd -X PUT
domain name will be updated
should not be updated
should be showed like 'Name is required'
if creating domain use 'id' for rest api version 1.6,the result is our expected,will be failed.
<text>Name is required and cannot be blank.</text>
Since we still have to support clients that use version 1.5 or earlier AND the routing in rails has to support ids. This cannot be fixed at this time.