Application structure refactoring