Minor cleanup
Factor out multi-lock behavior into its own class MultiLock.