Clean up all controllers, models, core and router to support the new Marley global.