pvary commented on a change in pull request #2772:
URL: https://github.com/apache/hive/pull/2772#discussion_r771281801



##########
File path: ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
##########
@@ -1273,14 +1276,21 @@ public void createTable(Table tbl, boolean ifNotExists,
           principalPrivs.setRolePrivileges(grants.getRoleGrants());
           tTbl.setPrivileges(principalPrivs);
         }
+        boolean createTableUseSuffix = (HiveConf.getBoolVar(conf, 
ConfVars.HIVE_ACID_CREATE_TABLE_USE_SUFFIX)
+            || HiveConf.getBoolVar(conf, 
ConfVars.HIVE_ACID_LOCKLESS_READS_ENABLED))
+          && AcidUtils.isTransactionalTable(tbl);
+
+        if (createTableUseSuffix) {
+          tTbl.setTxnId(ss.getTxnMgr().getCurrentTxnId());

Review comment:
       Do we have a context object where we can push this info instead of a 
`magical` flag?
   It would be better if we explicitly say "non-blocking" create, instead of 
depending on the txnId




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