예제 #1
0
 private void acquireLock(Lock lock) {
   try {
     if (!lock.tryLock(asyncStoreConfig.getFlushLockTimeout(), TimeUnit.MILLISECONDS))
       throw new CacheException("Unable to acquire lock on update map");
   } catch (InterruptedException ie) {
     // restore interrupted status
     Thread.currentThread().interrupt();
   }
 }