Refactoring of domain model