Split dependency_manager.js

Take classes out from dependency_manager.js