deniskuzZ commented on a change in pull request #1073: URL: https://github.com/apache/hive/pull/1073#discussion_r456421989
########## File path: standalone-metastore/metastore-tools/tools-common/src/main/java/org/apache/hadoop/hive/metastore/tools/HMSClient.java ########## @@ -345,21 +348,44 @@ boolean openTxn(int numTxns) throws TException { return openTxns; } + List<TxnInfo> getOpenTxnsInfo() throws TException { + return client.get_open_txns_info().getOpen_txns(); + } + boolean commitTxn(long txnId) throws TException { client.commit_txn(new CommitTxnRequest(txnId)); return true; } - boolean abortTxn(long txnId) throws TException { - client.abort_txn(new AbortTxnRequest(txnId)); + boolean abortTxns(List<Long> txnIds) throws TException { + client.abort_txns(new AbortTxnsRequest(txnIds)); return true; } - boolean abortTxns(List<Long> txnIds) throws TException { - client.abort_txns(new AbortTxnsRequest(txnIds)); + boolean allocateTableWriteIds(String dbName, String tableName, List<Long> openTxns) throws TException { + AllocateTableWriteIdsRequest awiRqst = new AllocateTableWriteIdsRequest(dbName, tableName); + openTxns.forEach(t -> { + awiRqst.addToTxnIds(t); + }); + + client.allocate_table_write_ids(awiRqst); return true; } + boolean getValidWriteIds(List<String> fullTableNames) throws TException { Review comment: I don't get what does it have to do with throwingSupplierWrapper. throwingSupplierWrapper just handles checked exceptions. ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For additional commands, e-mail: gitbox-h...@hive.apache.org