public interface LibraryCacheManager
| Modifier and Type | Method and Description |
|---|---|
ClassLoader |
getClassLoader(org.apache.flink.api.common.JobID id)
Returns the user code class loader associated with id.
|
boolean |
hasClassLoader(org.apache.flink.api.common.JobID jobId)
True if the LibraryCacheManager has a user code class loader registered
for the given job id.
|
void |
registerJob(org.apache.flink.api.common.JobID id,
Collection<PermanentBlobKey> requiredJarFiles,
Collection<URL> requiredClasspaths)
Registers a job with its required jar files and classpaths.
|
void |
registerTask(org.apache.flink.api.common.JobID id,
ExecutionAttemptID execution,
Collection<PermanentBlobKey> requiredJarFiles,
Collection<URL> requiredClasspaths)
Registers a job task execution with its required jar files and classpaths.
|
void |
shutdown()
Shutdown method which may release created class loaders.
|
void |
unregisterJob(org.apache.flink.api.common.JobID id)
Unregisters a job from the library cache manager.
|
void |
unregisterTask(org.apache.flink.api.common.JobID id,
ExecutionAttemptID execution)
Unregisters a job task execution from the library cache manager.
|
ClassLoader getClassLoader(org.apache.flink.api.common.JobID id)
id - identifying the jobvoid registerJob(org.apache.flink.api.common.JobID id,
Collection<PermanentBlobKey> requiredJarFiles,
Collection<URL> requiredClasspaths)
throws IOException
ClassLoader.id - job IDrequiredJarFiles - collection of blob keys identifying the required jar filesrequiredClasspaths - collection of classpaths that are added to the user code class loaderIOException - if any error occurs when retrieving the required jar filescounterpart of this methodvoid registerTask(org.apache.flink.api.common.JobID id,
ExecutionAttemptID execution,
Collection<PermanentBlobKey> requiredJarFiles,
Collection<URL> requiredClasspaths)
throws IOException
ClassLoader.id - job IDrequiredJarFiles - collection of blob keys identifying the required jar filesrequiredClasspaths - collection of classpaths that are added to the user code class loaderIOException - if any error occurs when retrieving the required jar filescounterpart of this methodvoid unregisterTask(org.apache.flink.api.common.JobID id,
ExecutionAttemptID execution)
Note: this is the counterpart of registerTask(JobID,
ExecutionAttemptID, Collection, Collection) and it will not remove any job added via
registerJob(JobID, Collection, Collection)!
id - job IDcounterpart of this methodvoid unregisterJob(org.apache.flink.api.common.JobID id)
Note: this is the counterpart of registerJob(JobID, Collection,
Collection) and it will not remove any job task execution added via registerTask(JobID, ExecutionAttemptID, Collection, Collection)!
id - job IDcounterpart of this methodvoid shutdown()
boolean hasClassLoader(@Nonnull org.apache.flink.api.common.JobID jobId)
jobId - identifying the job for which to check the class loaderCopyright © 2014–2020 The Apache Software Foundation. All rights reserved.