neils-dev commented on code in PR #3784:
URL: https://github.com/apache/ozone/pull/3784#discussion_r1012329902


##########
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/OzoneSnapshot.java:
##########
@@ -0,0 +1,120 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with this
+ * work for additional information regarding copyright ownership.  The ASF
+ * licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+ * License for the specific language governing permissions and limitations 
under
+ * the License.
+ */
+package org.apache.hadoop.ozone.client;
+
+import org.apache.hadoop.ozone.om.helpers.SnapshotInfo;
+import org.apache.hadoop.ozone.om.helpers.WithMetadata;
+
+/**
+ * A class that encapsulates OzoneSnapshot.
+ */
+public class OzoneSnapshot extends WithMetadata {

Review Comment:
   This client class does not appear to need to be extended from 
`WithMetadata`.  None of its( `WithMetadata`)  methods are used and the 
metadata datastructure within it is never used.



##########
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/OzoneSnapshot.java:
##########
@@ -0,0 +1,120 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with this
+ * work for additional information regarding copyright ownership.  The ASF
+ * licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+ * License for the specific language governing permissions and limitations 
under
+ * the License.
+ */
+package org.apache.hadoop.ozone.client;
+
+import org.apache.hadoop.ozone.om.helpers.SnapshotInfo;

Review Comment:
   Small change.  Using just `SnapshotInfo.SnapshotStatus `in this file.  The 
import can _change to_ `import 
org.apache.hadoop.ozone.om.helpers.SnapshotInfo.SnapshotStatus`.  Then 
declaration of variables can now be declared simply as` SnapshotStatus` type on 
lines ,
   
https://github.com/apache/ozone/blob/482f6d39c92e708200928490822a998995cee230/hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/OzoneSnapshot.java#L31
   and 
   
https://github.com/apache/ozone/blob/482f6d39c92e708200928490822a998995cee230/hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/OzoneSnapshot.java#L47
   



##########
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/ObjectStore.java:
##########
@@ -548,5 +549,15 @@ public String createSnapshot(String volumeName,
     return proxy.createSnapshot(volumeName, bucketName, snapshotName);
   }
 
-
+  /**
+   * List snapshots in a volume/bucket.
+   * @param volumeName volume name
+   * @param bucketName bucket name
+   * @return list of snapshot name

Review Comment:
   rewording the return javadoc to `return list of snapshots for volume/bucket 
snapshot path` from _return list of snapshot name_.



##########
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/rpc/RpcClient.java:
##########
@@ -931,6 +932,31 @@ public String createSnapshot(String volumeName,
         bucketName, snapshotName);
   }
 
+  /**
+   * List snapshots in a volume/bucket.
+   * @param volumeName volume name
+   * @param bucketName bucket name
+   * @return list of snapshot name

Review Comment:
   rewording javadoc return to something like _return list of snapshots for 
volume/bucket snapshotpath_.



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