public interface PythonFunctionFactory
| Modifier and Type | Interface and Description |
|---|---|
static class |
PythonFunctionFactory.CacheKey
The cache key.
|
| Modifier and Type | Field and Description |
|---|---|
static ScheduledExecutorService |
CACHE_CLEANUP_EXECUTOR_SERVICE |
static AtomicReference<Boolean> |
CACHE_CLEANUP_EXECUTOR_SERVICE_STARTED |
static org.apache.flink.shaded.guava18.com.google.common.cache.LoadingCache<PythonFunctionFactory.CacheKey,PythonFunctionFactory> |
PYTHON_FUNCTION_FACTORY_CACHE |
| Modifier and Type | Method and Description |
|---|---|
static PythonFunctionFactory |
createPythonFunctionFactory(org.apache.flink.configuration.ReadableConfig config) |
static void |
ensureCacheCleanupExecutorServiceStarted() |
static org.apache.flink.table.functions.python.PythonFunction |
getPythonFunction(String fullyQualifiedName,
org.apache.flink.configuration.ReadableConfig config,
ClassLoader classLoader)
Returns PythonFunction according to the fully qualified name of the Python UDF i.e
${moduleName}.${functionName} or ${moduleName}.${className}.
|
org.apache.flink.table.functions.python.PythonFunction |
getPythonFunction(String moduleName,
String objectName)
Returns PythonFunction according to moduleName and objectName.
|
static final ScheduledExecutorService CACHE_CLEANUP_EXECUTOR_SERVICE
static final AtomicReference<Boolean> CACHE_CLEANUP_EXECUTOR_SERVICE_STARTED
static final org.apache.flink.shaded.guava18.com.google.common.cache.LoadingCache<PythonFunctionFactory.CacheKey,PythonFunctionFactory> PYTHON_FUNCTION_FACTORY_CACHE
org.apache.flink.table.functions.python.PythonFunction getPythonFunction(String moduleName, String objectName)
moduleName - The module name of the Python UDF.objectName - The function name / class name of the Python UDF.static org.apache.flink.table.functions.python.PythonFunction getPythonFunction(String fullyQualifiedName, org.apache.flink.configuration.ReadableConfig config, ClassLoader classLoader) throws ExecutionException
fullyQualifiedName - The fully qualified name of the Python UDF.config - The configuration of python dependencies.classLoader - The classloader which is used to identify different jobs.ExecutionExceptionstatic void ensureCacheCleanupExecutorServiceStarted()
static PythonFunctionFactory createPythonFunctionFactory(org.apache.flink.configuration.ReadableConfig config) throws ExecutionException, InterruptedException, IOException
Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.