First commit - Refactoring Controller and TopologyManager