Interface LibraryCacheManager

All Known Implementing Classes:
BlobLibraryCacheManager

public interface LibraryCacheManager
The LibraryCacheManager is responsible for creating and managing the user code class loaders.

In order to obtain a user code class loader, one first needs to obtain a LibraryCacheManager.ClassLoaderLease for a given JobID. At first, the LibraryCacheManager.ClassLoaderLease is unresolved. In order to obtain the user class loader one needs to resolve it by specifying the required jar files and class paths. The user code class loader for a job is valid as long as there exists a valid LibraryCacheManager.ClassLoaderLease. A LibraryCacheManager.ClassLoaderLease becomes invalid once it gets released.

  • Method Details

    • registerClassLoaderLease

      LibraryCacheManager.ClassLoaderLease registerClassLoaderLease(org.apache.flink.api.common.JobID jobId)
      Registers a new class loader lease for the given jobId. The user code class loader for this job will be valid as long as there exists a valid lease for this job.
      Parameters:
      jobId - jobId for which to register a new class loader lease
      Returns:
      a new class loader lease for the given job
    • shutdown

      void shutdown()
      Shuts the library cache manager down. Thereby it will close all open LibraryCacheManager.ClassLoaderLease and release all registered user code class loaders.