add a locking model
extend lock