supporting more types of lock