snmvaughan commented on code in PR #4724:
URL: https://github.com/apache/hadoop/pull/4724#discussion_r951915598


##########
hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/qjournal/MiniQJMHACluster.java:
##########
@@ -35,7 +35,7 @@
 import java.util.List;
 import java.util.Random;
 
-public class MiniQJMHACluster {
+public class MiniQJMHACluster implements AutoCloseable {

Review Comment:
   That's was my mistake.  `close()` can't throw an exception, so the try-catch 
should have appeared in close.  The use of `AutoCloseable` allows 
try-with-resources which ensures that the resources are released properly.  
I've updated `TestRollingUpgrade` because it was consistently failing despite 
not being related to this change.
   
   I'll fix the exception handling to match the original `shutdown()` 
signature, and plan on opening a broader test update to take advantage of 
lessons learned here without other tests.



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