'entity' related refactoring.