steveloughran commented on code in PR #4806:
URL: https://github.com/apache/hadoop/pull/4806#discussion_r954779175


##########
hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/s3a/ITestS3AIOStatisticsContext.java:
##########
@@ -463,13 +464,18 @@ private class TestWorkerThread extends Thread implements 
Runnable {
 
     @Override
     public void run() {
+      // Setting the worker thread's name.
+      Thread.currentThread().setName("worker thread");
       S3AFileSystem fs = getFileSystem();
       byte[] data = new byte[BYTES_SMALL];
 
       // maybe switch context
       if (ioStatisticsContext != null) {
         IOStatisticsContext.setThreadIOStatisticsContext(ioStatisticsContext);
       }
+      // Storing context in a field to not loose the reference in a GC.

Review Comment:
   nit "lose"



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