Generic Application routing logic.