CFY-649 refactoring