Future<Void> f = fork(new Callable<Void>() {
@Override
public Void call() throws InterruptedException, TimeoutException {
final Object otherOwner = new Object();
for (int i =0; i < 10; i++) {
final OwnableReentrantLock ownableReentrantLock = lc.acquireLock(otherOwner, k2, 500, TimeUnit.MILLISECONDS);
log.trace("ownableReentrantLock = " + ownableReentrantLock);
if (ownableReentrantLock != null) return null;
}
throw new TimeoutException("We should have acquired lock!");
}