<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _task_complete(self, **kwargs):
 """ Performs cleanup tasks and notifies Job that the Task finished. """

        logger.debug('Running _task_complete for task {0}'.format(self.name))
        with self.parent_job.completion_lock:
            self.completed_at = datetime.utcnow()
            self.successful = kwargs.get('success', None)
            self.parent_job._complete_task(self.name, **kwargs)