A lock strategy determines when and how lock should be performed when downloading data to a
cache.
Note that some implementations may actually choose to NOT perform locking, when no lock is
necessary (cache not shared). Some other implementations may choose to lock the cache for the
download of a whole module (not possible yet), or at the artifact level.
The lock methods should return true when the lock is either actually acquired or not performed by
the strategy.
Locking used in the locking strategy must support reentrant lock. Reentrant locking should be
performed for the whole strategy.
|