Replace username with name

Keystone V2 API for user resource has field name instead of username.
This patch fixes this problem in samples, also fixes incorrect param
type.

Change-Id: I75e4282748a63a19b30593444fd9a6ea8c2c7af7
Closes-Bug: #1273860
This commit is contained in:
ZhiQiang Fan 2014-01-30 17:39:06 +08:00
parent e85c5e75e4
commit 2894dea2a5
14 changed files with 20 additions and 34 deletions

View File

@ -1,7 +1,7 @@
{
"user": {
"id": "u1000",
"username": "jqsmith",
"name": "jqsmith",
"email": "john.smith@example.org",
"enabled": true
}

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
enabled="true" email="john.smith@example.org"
username="jqsmith" id="u1000"/>
name="jqsmith" id="u1000"/>

View File

@ -1,16 +1,16 @@
{
"users":[{
"id": "u1000",
"username": "jqsmith",
"name": "jqsmith",
"email": "john.smith@example.org",
"enabled": true
},
{
"id": "u1001",
"username": "jqsmith",
"name": "jqsmith",
"email": "john.smith@example.org",
"enabled": true
}
],
"users_links":[]
}
}

View File

@ -2,8 +2,8 @@
<users xmlns="http://docs.openstack.org/identity/api/v2.0">
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
enabled="true" email="john.smith@example.org"
username="jqsmith" id="u1000"/>
name="jqsmith" id="u1000"/>
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
enabled="true" email="john.smith@example.org"
username="jqsmith" id="u1001"/>
name="jqsmith" id="u1001"/>
</users>

View File

@ -1,6 +1,6 @@
{
"user": {
"username": "jqsmith",
"name": "jqsmith",
"email": "john.smith@example.org",
"enabled": true,
"OS-KSADM:password": "secrete"

View File

@ -2,5 +2,5 @@
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
xmlns:OS-KSADM="http://docs.openstack.org/identity/api/ext/OS-KSADM/v1.0"
enabled="true" email="john.smith@example.org"
username="jqsmith"
name="jqsmith"
OS-KSADM:password="secrete"/>

View File

@ -1,7 +1,7 @@
{
"user": {
"id": "u1000",
"username": "jqsmith",
"name": "jqsmith",
"email": "john.smith@example.org",
"enabled": true
}

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
enabled="true" email="john.smith@example.org"
username="jqsmith" id="u1000"/>
name="jqsmith" id="u1000"/>

View File

@ -1,16 +1,16 @@
{
"users":[{
"id":"u1000",
"username":"jqsmith",
"name":"jqsmith",
"email":"john.smith@example.org",
"enabled":true
},
{
"id":"u1001",
"username":"jqsmith",
"name":"jqsmith",
"email":"john.smith@example.org",
"enabled":true
}
],
"users_links":[]
}
}

View File

@ -2,8 +2,8 @@
<users xmlns="http://docs.openstack.org/identity/api/v2.0">
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
enabled="true" email="john.smith@example.org"
username="jqsmith" id="u1000"/>
name="jqsmith" id="u1000"/>
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
enabled="true" email="john.smith@example.org"
username="jqsmith" id="u1001"/>
name="jqsmith" id="u1001"/>
</users>

View File

@ -1,6 +1,6 @@
{
"user": {
"username": "jqsmith",
"name": "jqsmith",
"email": "john.smith@example.org",
"enabled": true
}

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<user xmlns="http://docs.openstack.org/identity/api/v2.0"
enabled="true" email="john.smith@example.org"
username="jqsmith"/>
name="jqsmith"/>

View File

@ -418,12 +418,6 @@
<para role="shortdesc">Adds a user.</para>
</wadl:doc>
<request>
<param name="user" style="plain" required="true"
type="xsd:string">
<wadl:doc xmlns="http://docbook.org/ns/docbook"
xml:lang="EN"><para>The user
name.</para></wadl:doc>
</param>
<representation mediaType="application/xml"
element="identity:user">
<wadl:doc xmlns="http://docbook.org/ns/docbook"
@ -431,8 +425,8 @@
<xsdxt:code
href="../OS-KSADM/samples/userwithoutid.xml"/>
</wadl:doc>
<param name="user" style="plain" path="/identity:user"
type="UserForCreate">
<param name="name" style="plain" path="/identity:user"
type="String">
<wadl:doc xmlns="http://docbook.org/ns/docbook"
xml:lang="EN">The user name.</wadl:doc>
</param>

View File

@ -119,12 +119,4 @@
</complexContent>
</complexType>
<complexType name="UserForCreate">
<complexContent>
<extension base="identity:User">
<attribute ref="OS-KSADM:password" use="optional"/>
</extension>
</complexContent>
</complexType>
</schema>