Bug #38619
Updated by Abhishek Lekshmanan about 5 years ago
h1. Background: ceph version: 12.2.7 (3ec878d1e53e1aeb47a9f619c49d9e7c0aa384d5) luminous (stable) h1. Step to reproduce: <pre><code class="bash"> radosgw-admin user info --uid="test-user" </code></pre> <pre> { "user_id": "test-user", "display_name": "test-user", "email": "test-user@a.com", "keys": [ { "user": "test-user", "access_key": "AAAAAAAAAAAAAAAAAAA", "secret_key": "BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB" } ], } </pre> <code>test-user</code> already exists, then I can continue to use the create command but nothing seems to happen. <pre><code class="bash"> radosgw-admin user create --uid=test-user --display-name="test-user" </code></pre> But if I use the following command, I will receive an error that the user already has, and the exit code of the <code>radosgw-admin</code> command is <code>17</code> <pre><code class="bash"> radosgw-admin user create --uid=test-user # could not create user: unable to create user, user: test-user exists </code></pre> h1. Problem: *Why is there such a difference after the <code>--diplay-name</code> parameter?* In addition, I think the semantics of the interface design for creating users in the object storage <code>Admin Ops API</code> are not clear. Since all users are created, if this user already exists, it should return the error of <code>UserExists</code> or <code>EmailExists</code>, instead of adding a key for the user, as it is now.