Cleaning up repository

Added preliminary lock support to the backend, frontend needs to be
done.