Refactoring handler architecture.