Package hudson.remoting
Class FileSystemJarCache
java.lang.Object
hudson.remoting.JarCache
hudson.remoting.JarCacheSupport
hudson.remoting.FileSystemJarCache
JarCache
that stores files in a single directory.- Since:
- 2.24
- Author:
- Kohsuke Kawaguchi
-
Field Summary
Fields inherited from class hudson.remoting.JarCache
DEFAULT_NOWS_JAR_CACHE_LOCATION
-
Constructor Summary
-
Method Summary
Methods inherited from class hudson.remoting.JarCacheSupport
getJarLoader, resolve
-
Field Details
-
rootDir
-
-
Constructor Details
-
FileSystemJarCache
- Parameters:
rootDir
- Root directory.touch
- True to touch the cached jar file that's used. This enables external LRU based cache eviction at the expense of increased I/O.- Throws:
IllegalArgumentException
- Root directory isnull
or not writable.
-
-
Method Details
-
toString
-
lookInCache
protected URL lookInCache(Channel channel, long sum1, long sum2) throws IOException, InterruptedException Description copied from class:JarCacheSupport
Look up the local cache and return URL if found. Otherwise null (which will trigger a remote retrieval.)- Specified by:
lookInCache
in classJarCacheSupport
- Throws:
IOException
InterruptedException
-
retrieve
protected URL retrieve(Channel channel, long sum1, long sum2) throws IOException, InterruptedException Description copied from class:JarCacheSupport
Retrieve the jar file from the givenJarLoader
, store it, then return the URL to that jar.- Specified by:
retrieve
in classJarCacheSupport
- Returns:
- must not be null
- Throws:
IOException
InterruptedException
-