zhangyue19921010 commented on code in PR #6133:
URL: https://github.com/apache/hudi/pull/6133#discussion_r1028231466
##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/client/transaction/TransactionManager.java:
##########
@@ -67,6 +80,14 @@ public void endTransaction(Option<HoodieInstant>
currentTxnOwnerInstant) {
}
}
+ public void endTransaction(String filePath) {
Review Comment:
Sure, changed.
##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/config/HoodieLockConfig.java:
##########
@@ -189,6 +190,33 @@ public class HoodieLockConfig extends HoodieConfig {
.withDocumentation("Lock provider class name, this should be subclass of
"
+ "org.apache.hudi.client.transaction.ConflictResolutionStrategy");
+ // Pluggable strategies to use when early conflict detection
+ public static final ConfigProperty<String>
EARLY_CONFLICT_DETECTION_STRATEGY_CLASS_NAME = ConfigProperty
+ .key(LOCK_PREFIX + "early.conflict.detection.strategy")
+
.defaultValue(AsyncTimelineMarkerEarlyConflictDetectionStrategy.class.getName())
+ .sinceVersion("0.12.0")
+ .withDocumentation("Early conflict detection class name, this should be
subclass of "
+ +
"org.apache.hudi.common.conflict.detection.HoodieEarlyConflictDetectionStrategy");
+
+ public static final ConfigProperty<Boolean> EARLY_CONFLICT_DETECTION_ENABLE
= ConfigProperty
+ .key(LOCK_PREFIX + "early.conflict.detection.enable")
+ .defaultValue(false)
+ .sinceVersion("0.12.0")
+ .withDocumentation("Enable early conflict detection based on markers. It
will try to detect writing conflict before create markers and fast fail"
+ + " which will release cluster resources as soon as possible.");
+
+ public static final ConfigProperty<Long>
MARKER_CONFLICT_CHECKER_BATCH_INTERVAL = ConfigProperty
+ .key(LOCK_PREFIX + "early.conflict.async.checker.batch.interval")
+ .defaultValue(30000L)
+ .sinceVersion("0.12.0")
+ .withDocumentation("Used for timeline based marker
AsyncTimelineMarkerConflictResolutionStrategy. The time to delay first async
marker conflict checking.");
+
+ public static final ConfigProperty<Long> MARKER_CONFLICT_CHECKER_PERIOD =
ConfigProperty
+ .key(LOCK_PREFIX + "early.conflict.async.checker.period")
+ .defaultValue(30000L)
+ .sinceVersion("0.12.0")
+ .withDocumentation("Used for timeline based marker
AsyncTimelineMarkerConflictResolutionStrategy. The period between each marker
conflict checking.");
Review Comment:
all changed.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]