Commit 06bd3dae authored by Jonathan Mace's avatar Jonathan Mace
Browse files

add tohexstring method

parent 016ac195
...@@ -151,7 +151,7 @@ public class SparkTPCDSBatchGenerator { ...@@ -151,7 +151,7 @@ public class SparkTPCDSBatchGenerator {
System.out.println("Query " + query + " failed due to " + e.getClass().getSimpleName() + ": " + e.getMessage()); System.out.println("Query " + query + " failed due to " + e.getClass().getSimpleName() + ": " + e.getMessage());
errorreason = e.getClass().getSimpleName(); errorreason = e.getClass().getSimpleName();
} }
Object[] row = { end, iteration, query.benchmarkName(), query.queryName, query, end-begin, successful, errorreason, taskId, taskId+1 }; Object[] row = { end, iteration, query.benchmarkName(), query.queryName, query, end-begin, successful, errorreason, toHexString(taskId), toHexString(taskId+1) };
statusLog.println(StringUtils.join(row, "\t")); statusLog.println(StringUtils.join(row, "\t"));
statusLog.flush(); statusLog.flush();
...@@ -160,5 +160,9 @@ public class SparkTPCDSBatchGenerator { ...@@ -160,5 +160,9 @@ public class SparkTPCDSBatchGenerator {
statusLog.close(); statusLog.close();
} }
public static String toHexString(long value) {
return String.format("%16s", Long.toHexString(value)).replace(' ', '0');
}
} }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment