Configuration file hndler refactoring.
Configuration and cli refactoring