No file data is read as a result of doing the open, only meta-data
(size, owner, mtime, etc). It's true that both suggestions are
functionally equivalent. The relative performance of the two suggestions
depends on:
1. How many different cache managers access the file in one (say) 20-minute
interval.
2. How frequent the lock collisions are.
3. How many different files are being managed this way on the same machine.
At any rate, I expect the performance will only vary by 10% either way. If
it matters to you, implement both and measure them.