public abstract class CacheLoader extends Object implements AutoCloseable, Serializable
ScanTableSource.ScanRuntimeProvider.| Modifier and Type | Field and Description |
|---|---|
protected ConcurrentHashMap<org.apache.flink.table.data.RowData,Collection<org.apache.flink.table.data.RowData>> |
cache |
protected boolean |
isStopped |
protected static long |
TIMEOUT_AFTER_INTERRUPT_MS |
| Constructor and Description |
|---|
CacheLoader() |
| Modifier and Type | Method and Description |
|---|---|
void |
awaitFirstLoad() |
void |
close() |
ConcurrentHashMap<org.apache.flink.table.data.RowData,Collection<org.apache.flink.table.data.RowData>> |
getCache() |
void |
initializeMetrics(org.apache.flink.metrics.groups.CacheMetricGroup cacheMetricGroup) |
void |
open(org.apache.flink.configuration.Configuration parameters,
ClassLoader userCodeClassLoader) |
CompletableFuture<Void> |
reloadAsync() |
protected abstract boolean |
updateCache() |
protected static final long TIMEOUT_AFTER_INTERRUPT_MS
protected transient volatile ConcurrentHashMap<org.apache.flink.table.data.RowData,Collection<org.apache.flink.table.data.RowData>> cache
protected volatile boolean isStopped
protected abstract boolean updateCache()
throws Exception
Exceptionpublic void open(org.apache.flink.configuration.Configuration parameters,
ClassLoader userCodeClassLoader)
throws Exception
Exceptionpublic void initializeMetrics(org.apache.flink.metrics.groups.CacheMetricGroup cacheMetricGroup)
public ConcurrentHashMap<org.apache.flink.table.data.RowData,Collection<org.apache.flink.table.data.RowData>> getCache()
public void awaitFirstLoad()
throws InterruptedException
InterruptedExceptionpublic CompletableFuture<Void> reloadAsync()
public void close()
throws Exception
close in interface AutoCloseableExceptionCopyright © 2014–2025 The Apache Software Foundation. All rights reserved.