Vihang Karajgaonkar has posted comments on this change. ( http://gerrit.cloudera.org:8080/17569 )
Change subject: IMPALA-10740: MetastoreServiceHandler should extend DefaultThriftHiveMetastore ...................................................................... Patch Set 1: (1 comment) http://gerrit.cloudera.org:8080/#/c/17569/1/fe/src/main/java/org/apache/impala/catalog/metastore/MetastoreServiceHandler.java File fe/src/main/java/org/apache/impala/catalog/metastore/MetastoreServiceHandler.java: http://gerrit.cloudera.org:8080/#/c/17569/1/fe/src/main/java/org/apache/impala/catalog/metastore/MetastoreServiceHandler.java@340 PS1, Line 340: public IMetaStoreClient getMetaStoreClient() { : try (MetaStoreClient client = catalog_.getMetaStoreClient()){ : return client.getHiveClient(); : } This logic won't work. The try with resources block will put back the MetastoreClient into the pool again. This would cause a leak of IMetastoreClient from the MetaStoreClientPool and same IMetastoreClient could be used to issue multiple HMS API calls concurrently and may cause race conditions like (one thread closing the client while other thread is issuing a HMS call). -- To view, visit http://gerrit.cloudera.org:8080/17569 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I7e3f74dd96a7fec2ed13b0e5929f2b0a6b66e39f Gerrit-Change-Number: 17569 Gerrit-PatchSet: 1 Gerrit-Owner: Anonymous Coward <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Vihang Karajgaonkar <[email protected]> Gerrit-Comment-Date: Wed, 09 Jun 2021 21:52:51 +0000 Gerrit-HasComments: Yes
