Emitting an event when job is done