PRD-4225, PRD-4219 - Restructure/refactoring code for new MongoDb datasource; added partial infrastructure for dynamic modules