pvary commented on a change in pull request #2089:
URL: https://github.com/apache/hive/pull/2089#discussion_r608632190
##########
File path:
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/HMSHandler.java
##########
@@ -2419,9 +2419,9 @@ private void create_table_core(final RawStore ms, final
CreateTableRequest req)
}
if (!TableType.VIRTUAL_VIEW.toString().equals(tbl.getTableType())) {
- if (tbl.getSd().getLocation() == null
- || tbl.getSd().getLocation().isEmpty()) {
- tblPath = wh.getDefaultTablePath(db, tbl);
+ if (tbl.getSd().getLocation() == null ||
tbl.getSd().getLocation().isEmpty()) {
+ String relPath = tbl.getTableName() + (tbl.isSetTxnId() ? "_v" +
tbl.getTxnId() : "");
Review comment:
How is the new location looks like?
```
<WAREHOUSE_ROOT>/<DB_NAME>.db/<TABLE_NAME>_v<TXN_ID>
```
This might get mixed up if there are old tables, or tables created with
`hive.txn.nonblocking.droptable.enabled=false` and the name ends with _v1234.
Small chance, but...
What about using directories instead, like:
```
<WAREHOUSE_ROOT>/<DB_NAME>.db/<TABLE_NAME>/v_<TXN_ID>
```
--
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:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]