Refactoring how routing of different handler method works.