refactoring services config