[ 
https://issues.apache.org/jira/browse/HIVE-29571?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Marta Kuczora updated HIVE-29571:
---------------------------------
    Description: Currently the markCompacted call and the commitTxn call 
happens separately. The markCompacted call happens in the 
AcidCompactionService.compact method while the commitTxn happens in the close() 
method. This could lead to inconsistent state that the compaction is marked as 
finished and ready for cleaning, but the compaction transaction is still open. 
The compaction should not be marked as ready for cleaning until its txn is 
committed.  (was: Currently the markCompacted call and the commitTxn call 
happens separately. The markCompacted call happens in the 
AcidCompactionService.compact method while the commitTxn happens in the close() 
method. This could lead to inconsistent state that the compaction is marked as 
finished and ready for cleaning, but the compaction transaction is still open. 
We should check if we could handle this two calls in the same DB transaction to 
avoid such inconsistency.)

> ACID Compaction: Marking the compaction as compacted should happen after its 
> txn got committed
> ----------------------------------------------------------------------------------------------
>
>                 Key: HIVE-29571
>                 URL: https://issues.apache.org/jira/browse/HIVE-29571
>             Project: Hive
>          Issue Type: Task
>            Reporter: Marta Kuczora
>            Assignee: Marta Kuczora
>            Priority: Major
>
> Currently the markCompacted call and the commitTxn call happens separately. 
> The markCompacted call happens in the AcidCompactionService.compact method 
> while the commitTxn happens in the close() method. This could lead to 
> inconsistent state that the compaction is marked as finished and ready for 
> cleaning, but the compaction transaction is still open. The compaction should 
> not be marked as ready for cleaning until its txn is committed.



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

Reply via email to