refactoring spring