abstractdog commented on code in PR #402:
URL: https://github.com/apache/tez/pull/402#discussion_r2700956178


##########
tez-tests/src/main/java/org/apache/tez/mapreduce/examples/RandomTextWriter.java:
##########
@@ -180,70 +180,75 @@ public int run(String[] args) throws Exception {
     }
     
     Configuration conf = getConf();
-    JobClient client = new JobClient(conf);
+    try (JobClient client = new JobClient(conf)) {
+      return run(client, conf, args);
+    }
+  }
+
+  private int run (JobClient client, Configuration conf, String[] args) throws 
IOException, ClassNotFoundException, InterruptedException {
     ClusterStatus cluster = client.getClusterStatus();
     int numMapsPerHost = conf.getInt(MAPS_PER_HOST, 10);
     long numBytesToWritePerMap = conf.getLong(BYTES_PER_MAP,
-                                             1*1024*1024*1024);
+            1 * 1024 * 1024 * 1024);

Review Comment:
   I'm wondering if we need this line break here, it could be:
   ```
       long numBytesToWritePerMap = conf.getLong(BYTES_PER_MAP, 
1*1024*1024*1024);
   ```
   the same applies to:
   ```
         numBytesToWrite = conf.getLong(BYTES_PER_MAP, 1*1024*1024*1024);
   ```



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

Reply via email to