Extracted out StateInfoProtocol interface that can be replaced in the lock implementation that do not require fancy stuff.
Follow up refactoring, added reading of the state to the StateInfoProtocol interface.