add scoped_lock which implemented by RAII