[ 
https://issues.apache.org/jira/browse/HIVE-26922?focusedWorklogId=839862&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-839862
 ]

ASF GitHub Bot logged work on HIVE-26922:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 18/Jan/23 08:59
            Start Date: 18/Jan/23 08:59
    Worklog Time Spent: 10m 
      Work Description: kasakrisz commented on code in PR #3934:
URL: https://github.com/apache/hive/pull/3934#discussion_r1073259594


##########
ql/src/java/org/apache/hadoop/hive/ql/io/AcidUtils.java:
##########
@@ -3122,7 +3117,19 @@ Seems much cleaner if each stmt is identified as a 
particular HiveOperation (whi
     }
     return lockComponents;
   }
-  
+
+  private static LockType getLockTypeFromStorageHandler(WriteEntity output, 
Table t) {
+    final HiveStorageHandler storageHandler = 
Preconditions.checkNotNull(t.getStorageHandler(),
+        "Non-native tables must have an instance of storage handler.");
+    LockType lockType = storageHandler.getLockType(output);
+    if (null == LockType.findByValue(lockType.getValue())) {
+      throw new IllegalArgumentException(String
+          .format("Lock type [%s] for Database.Table [%s.%s] is unknown", 
lockType, t.getDbName(),

Review Comment:
   `getCompleteName()` uses `@` as separator char. I think without quoting db 
and table identifiers both separator chars (`.` and `@`) adds the same value 
since both of them can be part of the identifier.
   In this case this is not an issue because we just add the name to an 
exception message and the message also contains the format.





Issue Time Tracking
-------------------

    Worklog Id:     (was: 839862)
    Time Spent: 1.5h  (was: 1h 20m)

> Deadlock when rebuilding Materialized view stored by Iceberg
> ------------------------------------------------------------
>
>                 Key: HIVE-26922
>                 URL: https://issues.apache.org/jira/browse/HIVE-26922
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Krisztian Kasa
>            Assignee: Krisztian Kasa
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> {code}
> create table tbl_ice(a int, b string, c int) stored by iceberg stored as orc 
> tblproperties ('format-version'='1');
> insert into tbl_ice values (1, 'one', 50), (2, 'two', 51), (3, 'three', 52), 
> (4, 'four', 53), (5, 'five', 54);
> create materialized view mat1 stored by iceberg stored as orc tblproperties 
> ('format-version'='1') as
> select tbl_ice.b, tbl_ice.c from tbl_ice where tbl_ice.c > 52;
> insert into tbl_ice values (10, 'ten', 60);
> alter materialized view mat1 rebuild;
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to