refactor purge entry locking