Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-29793

Display an error when trying to create a user which already exists

    XMLWordPrintable

    Details

    • Release Notes Summary:
      User creation returns a HTTP 409 when the user already exists.
    • Backlog priority:
      550
    • Sprint:
      nxplatform #41, nxplatform #42
    • Story Points:
      2

      Description

      Steps to reproduce:

      1. create a first user whose username is jdoe
      2. go back to the user creation form
      3. fill the fields and use the same value "jdoe" for the username
      4. click on the Create button and observe that no error is displayed

      The problem can be observed either when
      1) you do not define a password. In this case,

      • you have this message in the browser console
        POST http://localhost:8080/nuxeo/api/v1/automation/User.Invite 500
        Operation request failed: Error
        
      • you have this error in the server logs
        ERROR [WebEngineExceptionMapper] org.nuxeo.ecm.platform.usermanager.exceptions.UserAlreadyExistsException: Failed to invoke operation: User.Invite, Failed to invoke operation User.Invite, null
        org.nuxeo.ecm.platform.usermanager.exceptions.UserAlreadyExistsException: Failed to invoke operation: User.Invite, Failed to invoke operation User.Invite, null
        

      2) you define a password: In this case, only an error is displayed in the browser console

      POST http://localhost:8080/nuxeo/api/v1/user 409
      Resource request failed: User already exists
      

      Expected behavior: in both cases, a message should warn the current actor that the user already exists.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 30 minutes
                30m