Dynamic Routing refactor