@Override
    public ClassLoaderLease registerClassLoaderLease(JobID jobId) {
        synchronized (lockObject) {
            return cacheEntries
                    .computeIfAbsent(jobId, jobID -> new LibraryCacheEntry(jobId))
                    .obtainLease();
        }
    }
@Test(expected = IOException.class)
    public void getOrResolveClassLoader_missingBlobKey_shouldFail() throws IOException {
        final PermanentBlobKey missingKey = new PermanentBlobKey();

        final BlobLibraryCacheManager libraryCacheManager = createSimpleBlobLibraryCacheManager();

        final LibraryCacheManager.ClassLoaderLease classLoaderLease =
                libraryCacheManager.registerClassLoaderLease(new JobID());

        classLoaderLease.getOrResolveClassLoader(
                Collections.singletonList(missingKey), Collections.emptyList());
    }