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

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

                Author: ASF GitHub Bot
            Created on: 25/Jan/23 13:50
            Start Date: 25/Jan/23 13:50
    Worklog Time Spent: 10m 
      Work Description: VenuReddy2103 commented on code in PR #3976:
URL: https://github.com/apache/hive/pull/3976#discussion_r1086664327


##########
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/ObjectStore.java:
##########
@@ -668,6 +671,20 @@ public void rollbackTransaction() {
     }
   }
 
+  private void setTransactionSavePoint(String savePoint) {
+    if (savePoint != null) {
+      ExecutionContext ec = ((JDOPersistenceManager) pm).getExecutionContext();
+      ec.getStoreManager().getConnectionManager().getConnection(ec);

Review Comment:
   I believe it is not required to check against null. These instances are 
created with the pm instance and cannot be null.





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

    Worklog Id:     (was: 841545)
    Time Spent: 40m  (was: 0.5h)

> Failure in direct SQL processing do not undo the changes made to database 
> before fallback to JDO resulting in stale entries in database forever
> -----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HIVE-26976
>                 URL: https://issues.apache.org/jira/browse/HIVE-26976
>             Project: Hive
>          Issue Type: Bug
>          Components: Metastore
>            Reporter: Venugopal Reddy K
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: image-2023-01-23-15-23-00-975.png
>
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> *[Description]* 
> Failure in direct SQL processing do not undo the changes made to database 
> before falling back to JDO based processing. Thus results in stale/dangling 
> entries in database forever.
> For instance, during dropPartitions() direct SQL processing, after dropping 
> rows from few tables(like PARTITIONS, PARTITION_PARAMS, PARTITION_KEY_VALS 
> etc), it causes typecast exception in dropStorageDescriptors() and fallback 
> to JDO processing. But datanucleus JDO processing cannot delete rows from 
> remaining tables(i.e., from sds, serdes, sds_params, serde_params, sort_cols, 
> bucketing_cols, skewed cols/values/location if any for the partitions) since 
> the partition is already deleted in the same transaction during direct SQL 
> processing.
> !image-2023-01-23-15-23-00-975.png!
>  
>  
> *[Steps to reproduce]* 
> Reproduction steps are described in issue - 
> https://issues.apache.org/jira/browse/HIVE-26860



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

Reply via email to