reschke commented on code in PR #2868:
URL: https://github.com/apache/jackrabbit-oak/pull/2868#discussion_r3246782874
##########
oak-jackrabbit-api/src/main/java/org/apache/jackrabbit/api/security/user/UserManager.java:
##########
@@ -213,6 +213,34 @@ User createUser(@NotNull String userID, @Nullable String
password, @NotNull Prin
@Nullable String intermediatePath) throws
AuthorizableExistsException, RepositoryException;
+ /**
+ * Creates a user for the given parameters at the specified absolute Oak
path.
+ * Unlike {@link #createUser(String, String, Principal, String)} where the
+ * {@code intermediatePath} is a relative hint, this method accepts an
absolute
+ * repository path that precisely determines the location of the new user
node.
+ * <p>
+ * Implementations that do not support placement at an arbitrary absolute
path
+ * should throw {@link UnsupportedRepositoryOperationException}.
+ *
+ * @param userID The ID of the new user.
+ * @param password The initial password of the new user, may be
{@code null}.
+ * @param principal The principal of the new user.
+ * @param absoluteOakPath The absolute Oak repository path at which the
user node
+ * must be created. Must not be {@code null}.
+ * @return The new {@code User}.
+ * @throws AuthorizableExistsException if an authorizable
with the given
+ * userID or principal
already exists.
+ * @throws UnsupportedRepositoryOperationException if the implementation
does not
+ * support creation at an
absolute path.
+ * @throws RepositoryException If another error
occurs.
+ */
+ @NotNull
+ default User createUserWithAbsolutePath(@NotNull String userID, @Nullable
String password,
+ @NotNull Principal principal,
@NotNull String absoluteOakPath)
+ throws AuthorizableExistsException,
UnsupportedRepositoryOperationException, RepositoryException {
+ throw new
UnsupportedRepositoryOperationException("createUserWithAbsolutePath is not
supported by this implementation");
Review Comment:
actually, that is really really important.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]