sumitagrawl commented on code in PR #7647:
URL: https://github.com/apache/ozone/pull/7647#discussion_r1925063255
##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/OMClientRequest.java:
##########
@@ -122,6 +123,13 @@ public OMRequest preExecute(OzoneManager ozoneManager)
return omRequest;
}
+ public OmLockOpr.OmLockInfo lock(OzoneManager ozoneManager, OmLockOpr
lockOpr) throws IOException {
+ return null;
+ }
+
+ public void unlock(OmLockOpr lockOpr, OmLockOpr.OmLockInfo lockInfo) {
+ }
Review Comment:
Lock key needs to be obtained from Request Object structure, and its
different for different request.
So its not possible to get this directly as AOP. Two way of implementation:
1. Switch case of each request type, and retrieve the lock information based
on this
-- This is tried out but that class itself looks complex and un-manageble
2. Each request handle define how it can get and call respective lock
3. Some operation do not need any lock, so provided with default
implementation on no lock
--
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]