change write and get lock