refactoring config structure to maintain more clean separation