Fix refactoring bugs that broke the command line
Refactored the managers to allow to add library clients