Split large code base into separate classes. Use Service as a controller, in order to define tasks to execute.