Vihang Karajgaonkar has posted comments on this change. ( http://gerrit.cloudera.org:8080/14005 )
Change subject: Bump CDP_BUILD_NUMBER to 1318335 ...................................................................... Patch Set 3: > From yesterdays FE meeting, Vihang prefer following fix: > --- a/tests/common/impala_test_suite.py > +++ b/tests/common/impala_test_suite.py > @@ -81,6 +81,7 @@ from tests.util.thrift_util import > create_transport > > # Imports required for Hive Metastore Client > from hive_metastore import ThriftHiveMetastore > +from hive_metastore import ttypes > from thrift.protocol import TBinaryProtocol > > # Initializing the logger before conditional imports, since we will > need it > @@ -122,7 +123,6 @@ SET_PATTERN = re.compile( > METRICS_URL = 'http://localhost:25000/metrics?json' > > GROUP_NAME = grp.getgrgid(pwd.getpwnam(getuser()).pw_gid).gr_name > - > # Base class for Impala tests. All impala test cases should inherit > from this class > class ImpalaTestSuite(BaseTestSuite): > @classmethod > @@ -806,7 +806,14 @@ class ImpalaTestSuite(BaseTestSuite): > table = self.hive_client.get_table(db_name, table_name) > assert table is not None > self.hive_client.drop_table(db_name, table_name, True) > - self.hive_client.create_table(table) > + if HIVE_MAJOR_VERSION > 2: > + capabilities = ["EXTREAD", "EXTWRITE","HIVEBUCKET2", > "HIVEMANAGEDINSERTREAD", > + "HIVEMANAGEDINSERTWRITE", "HIVEMQT", "HIVEFULLACIDREAD", > "HIVEFULLACIDWRITE"] > + createTblRequest = ttypes.CreateTableRequest(table, > + processorCapabilities=capabilities, > processorIdentifier="ImpalatestPython") > + self.hive_client.create_table_req(createTblRequest) > + else: > + self.hive_client.create_table(table) Thanks Yonghzi .. The above code looks right to me. I would update the comment in the MetastoreShim setCapabilities() so that we are aware that any change in that method would like mean a change in this part of the code as well. Not sure if we have to do this for other APIs as well? I see in HiveMetastoreClient we send the capabilities in getPartitionByNames, and some getTable API variations too. We don't have to implement it in all the APIs but only the ones which we use. -- To view, visit http://gerrit.cloudera.org:8080/14005 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I432e8c02dbd349a3507bfabfef2727914537652c Gerrit-Change-Number: 14005 Gerrit-PatchSet: 3 Gerrit-Owner: Csaba Ringhofer <[email protected]> Gerrit-Reviewer: Csaba Ringhofer <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Vihang Karajgaonkar <[email protected]> Gerrit-Reviewer: Yongzhi Chen <[email protected]> Gerrit-Comment-Date: Tue, 06 Aug 2019 16:36:43 +0000 Gerrit-HasComments: No
