fixes #26 made lock recovery more efficient by caching and batching

I am undecided on this.   I have seen so many cases where comments drift from implementation and become meaningless or even misleading.   On the other hand, we have the chance to set good precedents in this young project.  Encourage useful comments during code review and encourage updating comments that have skewed during code review.

I'll add some comments and we can see how it goes.  If a year from now comments are getting skewed, we can re-evaluate.