refactor the usage of the configuration