smengcl commented on a change in pull request #806: HDDS-3374.
OMVolumeSetOwnerRequest doesn't check if user is already the owner
URL: https://github.com/apache/hadoop-ozone/pull/806#discussion_r408257039
##########
File path:
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/response/volume/OMVolumeSetOwnerResponse.java
##########
@@ -55,11 +56,27 @@ public OMVolumeSetOwnerResponse(@Nonnull OMResponse
omResponse,
/**
* For when the request is not successful or it is a replay transaction.
Review comment:
Just BTW in a discussion with @bharatviswa504 we concluded that the reason
of setting success to `false` for "newOwner equals to oldOwner" case is that in
[`addAcl`](https://github.com/apache/hadoop-ozone/blob/ebc616061da6f337626ee85e4282230aedfd748a/hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/shell/acl/AclOption.java#L58-L62)
we have some logic to print different results on the client depending on the
success flag. Though the success flag of `setOwner` isn't utilized at the
moment, we might be able to use it later.
And reason of returning status OK is that the client will throw exception if
the status isn't OK.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]