refactored mark.controller and worker