Simplified lock object.
Added queuelayer.js and associated tests.
Updated counterlayer and associated tests.