smengcl commented on code in PR #7463:
URL: https://github.com/apache/ozone/pull/7463#discussion_r1853226907


##########
hadoop-ozone/tools/src/main/java/org/apache/hadoop/ozone/freon/HsyncGenerator.java:
##########
@@ -16,35 +16,39 @@
  */
 package org.apache.hadoop.ozone.freon;
 
-import java.util.concurrent.Callable;
-import java.util.concurrent.atomic.AtomicInteger;
-
+import com.codahale.metrics.Timer;
 import com.google.common.annotations.VisibleForTesting;
 import org.apache.hadoop.fs.FSDataOutputStream;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.hdds.cli.HddsVersionProvider;
 import org.apache.hadoop.hdds.conf.OzoneConfiguration;
-
-import com.codahale.metrics.Timer;
 import org.apache.hadoop.ozone.util.PayloadUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import picocli.CommandLine;
 import picocli.CommandLine.Command;
 import picocli.CommandLine.Option;
 
+import java.io.IOException;
+import java.net.URI;
+import java.util.concurrent.ArrayBlockingQueue;
+import java.util.concurrent.BlockingQueue;
+import java.util.concurrent.Callable;
+import java.util.concurrent.atomic.AtomicInteger;
+
 /**
  * Data generator tool test hsync/write synchronization performance.
+ * This tool simulates the way HBase writes transaction logs (WAL) to a file 
in Ozone:
+ *  - Transactions are written to the file's OutputStream by a single thread, 
each transaction is numbered by an
+ *  increasing counter. Every transaction can be serialized to the 
OutputStream via multiple write calls.
+ *  - Multiple threads checks and sync (hsync) the OutputStream to make it 
persistent.
  *
  * Example usage:
  *
- * To generate 1000 hsync calls with 10 threads on a single file:
- *    ozone freon hsync-generator -t 10 --bytes-per-write=1024 -n 1000
- *
- * To generate 1000 hsync calls with 10 threads on 3 files simultaneously:
+ * To simulate hlog that generates 1M hsync calls with 5 threads:
  *
- *    ozone freon hsync-generator -t 10 --bytes-per-write=1024 
--number-of-files=3 -n 1000
+ *    ozone freon hlog-emulator -t 5 --writes-per-transaction=32 
--bytes-per-write=8 -n 1000000

Review Comment:
   looks like the subcommand name hasn't changed
   
   ```suggestion
    *    ozone freon hsync-generator -t 5 --writes-per-transaction=32 
--bytes-per-write=8 -n 1000000
   ```



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