add inversed read-write lock for data consistency