deniskuzZ commented on code in PR #5691:
URL: https://github.com/apache/hive/pull/5691#discussion_r2010051303
##########
iceberg/iceberg-catalog/src/main/java/org/apache/iceberg/hive/MetastoreLock.java:
##########
@@ -102,6 +103,7 @@ public MetastoreLock(Configuration conf,
ClientPool<IMetaStoreClient, TException
this.fullName = catalogName + "." + databaseName + "." + tableName;
this.databaseName = databaseName;
this.tableName = tableName;
+ this.conf = conf;
Review Comment:
@kasakrisz , why did you do that? I think I've shared with you the proper
way to do that
HiveIcebergOutputCommitter#commitTable
````
long txnId = Optional.ofNullable(SessionState.get())
.map(ss -> ss.getTxnMgr().getCurrentTxnId()).orElse(0L);
((BaseTable) table).operations().current().properties().put("txnId",
Long.toString(txnId));
````
HiveTableOperations
````
HiveLock lockObject(TableMetadata metadata) {
if (hiveLockEnabled(metadata, conf)) {
return new MetastoreLock(conf, metaClients, catalogName, database,
tableName,
metadata.propertyAsLong("txnId", 0));
} else {
return new NoLock();
}
}
````
using conf is not correct, since it's a global catalog conf
--
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]