You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "LZD-PratyushBhatt (via GitHub)" <gi...@apache.org> on 2023/09/08 02:29:46 UTC

[GitHub] [ozone] LZD-PratyushBhatt opened a new pull request, #5259: HDDS-9255. LeaseRecovery CLI Should work for O3fs path

LZD-PratyushBhatt opened a new pull request, #5259:
URL: https://github.com/apache/ozone/pull/5259

   ## What changes were proposed in this pull request?
   
   Currently, the Lease Recovery CLI only checks for RootedOzoneFileSystem, so any o3fs path throws an unsupported filesystem error. The aim is to make the CLI work for OzoneFileSystem too.
   
   ## What is the link to the Apache JIRA
   
   [HDDS-9255](https://issues.apache.org/jira/browse/HDDS-9255)
   
   ## How was this patch tested?
   
   
   


-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] jojochuang commented on a diff in pull request #5259: HDDS-9255. LeaseRecovery CLI Should work for O3fs path.

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on code in PR #5259:
URL: https://github.com/apache/ozone/pull/5259#discussion_r1321832801


##########
hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/debug/LeaseRecoverer.java:
##########
@@ -74,6 +75,8 @@ public Void call() throws Exception {
     FileSystem fs = FileSystem.get(uri, configuration);
     if (fs instanceof RootedOzoneFileSystem) {
       ((RootedOzoneFileSystem) fs).recoverLease(new Path(uri));
+    } else if (fs instanceof OzoneFileSystem) {
+      ((OzoneFileSystem) fs).recoverLease(new Path(uri));

Review Comment:
   need to import LeaseRecoverable too.



-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] LZD-PratyushBhatt commented on pull request #5259: HDDS-9255. LeaseRecovery CLI Should work for O3fs path.

Posted by "LZD-PratyushBhatt (via GitHub)" <gi...@apache.org>.
LZD-PratyushBhatt commented on PR #5259:
URL: https://github.com/apache/ozone/pull/5259#issuecomment-1714288968

   > Other than that it looks good.
   > 
   > There's also a TestLeaseRecoverer but it's a good idea to have robot test coverage as well. Do you think we should add the same for ofs?
   
   Sure, I'll add the same for ofs too.


-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] jojochuang commented on a diff in pull request #5259: HDDS-9255. LeaseRecovery CLI Should work for O3fs path.

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on code in PR #5259:
URL: https://github.com/apache/ozone/pull/5259#discussion_r1321827573


##########
hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/debug/LeaseRecoverer.java:
##########
@@ -74,6 +75,8 @@ public Void call() throws Exception {
     FileSystem fs = FileSystem.get(uri, configuration);
     if (fs instanceof RootedOzoneFileSystem) {
       ((RootedOzoneFileSystem) fs).recoverLease(new Path(uri));
+    } else if (fs instanceof OzoneFileSystem) {
+      ((OzoneFileSystem) fs).recoverLease(new Path(uri));

Review Comment:
   In fact, we can now simplify it with 
   ```suggestion
       if (fs instanceof LeaseRecoverable) {
         ((LeaseRecoverable) fs).recoverLease(new Path(uri));
   ```



-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] jojochuang merged pull request #5259: HDDS-9255. LeaseRecovery CLI Should work for O3fs path.

Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang merged PR #5259:
URL: https://github.com/apache/ozone/pull/5259


-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] LZD-PratyushBhatt commented on a diff in pull request #5259: HDDS-9255. LeaseRecovery CLI Should work for O3fs path.

Posted by "LZD-PratyushBhatt (via GitHub)" <gi...@apache.org>.
LZD-PratyushBhatt commented on code in PR #5259:
URL: https://github.com/apache/ozone/pull/5259#discussion_r1321868878


##########
hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/debug/LeaseRecoverer.java:
##########
@@ -74,6 +75,8 @@ public Void call() throws Exception {
     FileSystem fs = FileSystem.get(uri, configuration);
     if (fs instanceof RootedOzoneFileSystem) {
       ((RootedOzoneFileSystem) fs).recoverLease(new Path(uri));
+    } else if (fs instanceof OzoneFileSystem) {
+      ((OzoneFileSystem) fs).recoverLease(new Path(uri));

Review Comment:
   Made the changes, please review. Thanks!



-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


[GitHub] [ozone] LZD-PratyushBhatt commented on pull request #5259: HDDS-9255. LeaseRecovery CLI Should work for O3fs path.

Posted by "LZD-PratyushBhatt (via GitHub)" <gi...@apache.org>.
LZD-PratyushBhatt commented on PR #5259:
URL: https://github.com/apache/ozone/pull/5259#issuecomment-1714286337

   > Other than that it looks good.
   > 
   > There's also a TestLeaseRecoverer but it's a good idea to have robot test coverage as well. Do you think we should add the same for ofs?
   
   Sure, I'll add the same for ofs too.


-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org