adoroszlai commented on code in PR #7400:
URL: https://github.com/apache/ozone/pull/7400#discussion_r1832105324
##########
hadoop-ozone/dist/src/main/smoketest/compatibility/write.robot:
##########
@@ -40,3 +44,13 @@ FSO Bucket Can Be Created and Used
Execute ozone sh bucket create --layout FILE_SYSTEM_OPTIMIZED
/vol1/fso-bucket-${SUFFIX}
Execute ozone fs -mkdir -p ofs://om/vol1/fso-bucket-${SUFFIX}/dir/subdir
Execute ozone fs -put ${TESTFILE}
ofs://om/vol1/fso-bucket-${SUFFIX}/dir/subdir/file
+
+HSync Can Be Used To Create Keys
+ Pass Execution If '${CLIENT_VERSION}' < '${HSYNC_VERSION}' Client
does not support HSYNC
+ Pass Execution If '${CLUSTER_VERSION}' < '${HSYNC_VERSION}' Cluster
does not support HSYNC
+ Execute ozone sh volume create /${VOL}
+ Execute ozone sh bucket create /${VOL}/${BUCK}
+ ${o3fspath} = Format FS URL o3fs ${VOL} ${BUCK}
+ Freon DFSG sync=HSYNC path=${o3fspath}
+ ${pfspath} = Format FS URL ofs ${VOL} ${BUCK}
+ Freon DFSG sync=HSYNC path=${pfspath}
Review Comment:
Please use `vol1` and `bucket1` here.
Rationale:
- `write.robot` is executed against the same cluster by multiple clients
(with various versions)
- `${VOL}` and `${BUCK}` always have the same values
- creation will fail as soon as we have two versions that both support hsync
- new volume and bucket are not necessary for this specific test case
- `vol1` and `bucket1` are pre-created:
https://github.com/apache/ozone/blob/0415c0b4f7179e56e76ac57bb1974915729c3ef7/hadoop-ozone/dist/src/main/compose/xcompat/test.sh#L91
For unique items to be created per client version, please use `${SUFFIX}`,
which is
[set](https://github.com/apache/ozone/blob/0415c0b4f7179e56e76ac57bb1974915729c3ef7/hadoop-ozone/dist/src/main/compose/xcompat/test.sh#L62)
by `test.sh`. It is up to each test case how they use that suffix. E.g. a
test that creates buckets would append it to the bucket name. That's why there
are no variables for volume/bucket name.
```suggestion
${o3fspath} = Format FS URL o3fs vol1 bucket1
Freon DFSG sync=HSYNC path=${o3fspath}
${ofspath} = Format FS URL ofs vol1 bucket1
Freon DFSG sync=HSYNC path=${ofspath}
```
##########
hadoop-ozone/dist/src/main/smoketest/compatibility/read.robot:
##########
@@ -46,3 +46,9 @@ FSO Bucket Can Be Read
Execute ozone fs -get
ofs://om/vol1/fso-bucket-${SUFFIX}/dir/subdir/file ${TEMP_DIR}/
Execute diff -q ${TESTFILE} ${TEMP_DIR}/file
[teardown] Execute rm -f ${TEMP_DIR}/file
+
+HSync Lease Recover Can Be Used
+ Pass Execution If '${DATA_VERSION}' < '${HSYNC_VERSION}' Skipped
the test case
Review Comment:
It looks like write and read test cases for HSync are independent. This
read test case uses the file created by the FSO test case as input. Therefore
here we do not need skip based on `${HSYNC_VERSION}`, but `${FSO_VERSION}`.
```suggestion
Pass Execution If '${DATA_VERSION}' < '${FSO_VERSION}' Skipped
the test case
```
##########
hadoop-ozone/dist/src/main/smoketest/compatibility/write.robot:
##########
@@ -17,11 +17,15 @@
Documentation Write Compatibility
Resource ../ozone-lib/shell.robot
Resource setup.robot
+Resource ../lib/fs.robot
+Resource ../ozone-lib/freon.robot
Test Timeout 5 minutes
Suite Setup Create Local Test File
*** Variables ***
${SUFFIX} ${EMPTY}
+${VOL} comp-hsync-volume
+${BUCK} comp-hsync-bucket
Review Comment:
```suggestion
```
--
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]