Request a lock from this LockManager instance.
if(username == null)
return false; // or raise exception
synchronized(locks) {
if(!locks.containsKey(lockable)) {
locks.put(lockable, username);
return true;
}
// Return true if this user already has a lock
return (username.equals(locks.get(lockable)));
}