public class TransactionUtils extends Object
| Constructor and Description |
|---|
TransactionUtils() |
| Modifier and Type | Method and Description |
|---|---|
static Stream<HoodieInstant> |
getCompletedInstantsDuringCurrentWriteOperation(HoodieTableMetaClient metaClient,
Set<String> pendingInstants) |
static Set<String> |
getInflightAndRequestedInstants(HoodieTableMetaClient metaClient)
Get InflightAndRequest instants.
|
static Option<Pair<HoodieInstant,Map<String,String>>> |
getLastCompletedTxnInstantAndMetadata(HoodieTableMetaClient metaClient)
Get the last completed transaction hoodie instant and
HoodieCommitMetadata.getExtraMetadata(). |
static Option<HoodieCommitMetadata> |
resolveWriteConflictIfAny(HoodieTable table,
Option<HoodieInstant> currentTxnOwnerInstant,
Option<HoodieCommitMetadata> thisCommitMetadata,
HoodieWriteConfig config,
Option<HoodieInstant> lastCompletedTxnOwnerInstant,
boolean reloadActiveTimeline,
Set<String> pendingInstants)
Resolve any write conflicts when committing data.
|
public static Option<HoodieCommitMetadata> resolveWriteConflictIfAny(HoodieTable table, Option<HoodieInstant> currentTxnOwnerInstant, Option<HoodieCommitMetadata> thisCommitMetadata, HoodieWriteConfig config, Option<HoodieInstant> lastCompletedTxnOwnerInstant, boolean reloadActiveTimeline, Set<String> pendingInstants) throws HoodieWriteConflictException
table - currentTxnOwnerInstant - thisCommitMetadata - config - lastCompletedTxnOwnerInstant - pendingInstants - HoodieWriteConflictExceptionpublic static Option<Pair<HoodieInstant,Map<String,String>>> getLastCompletedTxnInstantAndMetadata(HoodieTableMetaClient metaClient)
HoodieCommitMetadata.getExtraMetadata().metaClient - public static Set<String> getInflightAndRequestedInstants(HoodieTableMetaClient metaClient)
metaClient - public static Stream<HoodieInstant> getCompletedInstantsDuringCurrentWriteOperation(HoodieTableMetaClient metaClient, Set<String> pendingInstants)
Copyright © 2022 The Apache Software Foundation. All rights reserved.