java - CreateUser in DefaultUserAccessor -
can please explain difference between createuser(string) , createuser(user,credential) in confluence. want create 1 user confluence, if user not there in group. there no information in confluence documentation. :(
i wrote code this, not sure whetehr accept createuser method twice in same line.
useraccessor.createuser(useraccessor.createuser(username), credential.encrypted(password));
i guesing, if inside createuser executed,then throw exception @ outside parent createuser trying create same user again?
please give me thoughts
thanks samuel.
the new createuser(user, credential) method replaces old createuser(string) method, should use former , construct user details:
user user = useraccessor.createuser(new defaultuser("mryall", "matt ryall", "matt@mattryall.net"), credential.unencrypted("secret")); the reason having api reduce number of calls needed create user, , fix potential race condition you're creating user username otherwise empty fields (name, email, password).
this entire api poorly documented. work on confluence team @ atlassian - mea culpa! we'll try fixed.
Comments
Post a Comment