adoroszlai commented on code in PR #9629:
URL: https://github.com/apache/ozone/pull/9629#discussion_r2711452513


##########
hadoop-ozone/recon/src/test/java/org/apache/hadoop/ozone/recon/api/TestOmDBInsightEndPoint.java:
##########
@@ -350,6 +354,12 @@ public void tearDown() throws Exception {
     if (reconOMMetadataManager != null) {
       reconOMMetadataManager.stop();
     }
+    if (ozoneStorageContainerManager != null) {
+      ozoneStorageContainerManager.stop();
+    }
+    if (reconDBProvider != null) {
+      reconDBProvider.close();

Review Comment:
   Thanks @ArafatKhan2198 for updating the patch.
   
   `ReconTestInjector` is created `withContainerDB` in `@BeforeEach` of some 
other tests.  Don't they need to close it?
   
   Examples:
   - TestClusterStateEndpoint
   - TestDeletedKeysSearchEndpoint
   - TestOpenKeysSearchEndpoint
   
   (There may be more.)
   
   Also, it would be better to add `ReconTestInjector.close()` to clean up all 
resources it created, and let tests call that single method instead of storing 
and closing `reconDBProvider`, which is otherwise not directly used in the test.



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