ivandika3 commented on code in PR #11056:
URL: https://github.com/apache/ozone/pull/11056#discussion_r3852141075


##########
hadoop-ozone/common/src/main/java/org/apache/hadoop/ozone/om/protocolPB/OzoneManagerProtocolClientSideTranslatorPB.java:
##########
@@ -779,7 +779,7 @@ public OpenKeySession openKey(OmKeyArgs args) throws 
IOException {
   private OMResponse handleError(OMResponse resp) throws OMException {
     if (resp.getStatus() != OK) {
       throw new OMException(resp.getMessage(),
-          ResultCodes.values()[resp.getStatus().ordinal()]);
+          ResultCodes.valueOf(resp.getStatus().name()));

Review Comment:
   > error-code translation for any status where the Status and ResultCodes 
ordinals differ
   
   I'm not sure I follow this, this patch does not use `Status` ordinal.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to