Rewrite the topology manager, to support controller argument