public class WaitBasedTimeGenerator extends TimeGeneratorBase
config| Constructor and Description |
|---|
WaitBasedTimeGenerator(HoodieTimeGeneratorConfig config,
StorageConfiguration<?> storageConf) |
| Modifier and Type | Method and Description |
|---|---|
void |
consumeTimestamp(boolean skipLocking,
Consumer<Long> func)
Passes an auto generated timestamp to the given function
func. |
long |
currentTimeMillis(boolean skipLocking)
Generates a globally monotonically increasing timestamp.
|
getLockProvider, lock, unlockpublic WaitBasedTimeGenerator(HoodieTimeGeneratorConfig config, StorageConfiguration<?> storageConf)
public long currentTimeMillis(boolean skipLocking)
TimeGeneratorskipLocking - If this is triggered by another parent transaction, locking can be skipped.public void consumeTimestamp(boolean skipLocking,
Consumer<Long> func)
TimeGeneratorfunc. The implementations
need to ensure timestamp generation and executing func are atomic.skipLocking - If this is triggered by another parent transaction, locking can be skipped.func - A consumer that takes a monotonically increasing timestamp.Copyright © 2024 The Apache Software Foundation. All rights reserved.