I wasn't thinking of a flag, I was thinking of a withTimeout(timeout) method on AdvancedCache. There may be other "flags" that could be customized with a value as well, but then you'd need to keep them in a map and it could be more trouble than it's worth. The complication with withTimeout/tryLock OTOH is that as a user I'd expect it to limit everything, not just the lock acquisition - so it would have to override sync.replTimeout as well.
Flag.FAIL_SILENTLY
.".