Nir Soffer has submitted this change and it was merged.

Change subject: jobs: Autodelete

jobs: Autodelete

For storage jobs we like to delete finished jobs automatically after
some delay, giving engine enough time to discover the job completion
state in most cases, and allowing easy inspection of job state.  The Job
class implements now both run() and abort(), managing the state changes
and auto-deleting the job when done. Subclasses should implement _run()
and _abort().

To intergate with v2v code using old jobs framework, v2v code will have
to use _run() instead of run(). Subclass that want to enable autodelete
must override the autodelete class attribute and set it to True.

class AutodeletingJob(jobs.Job):
    autodelete = True

This feature is not relevant now for v2v jobs since engine is deleting
these jobs.

Change-Id: I4aafd2271397bd9bc4289dc1aab723398d475add
Signed-off-by: Adam Litke <>
Signed-off-by: Nir Soffer <>
Continuous-Integration: Jenkins CI
Reviewed-by: Francesco Romani <>
Reviewed-by: Piotr Kliczewski <>
M lib/vdsm/
M lib/vdsm/
M tests/
M vdsm/storage/sdm/api/
4 files changed, 87 insertions(+), 2 deletions(-)

  Piotr Kliczewski: Looks good to me, but someone else must approve
  Nir Soffer: Looks good to me, approved
  Adam Litke: Verified
  Jenkins CI: Passed CI tests
  Francesco Romani: Looks good to me, but someone else must approve

To view, visit
To unsubscribe, visit

Gerrit-MessageType: merged
Gerrit-Change-Id: I4aafd2271397bd9bc4289dc1aab723398d475add
Gerrit-PatchSet: 10
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Adam Litke <>
Gerrit-Reviewer: Adam Litke <>
Gerrit-Reviewer: Francesco Romani <>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <>
Gerrit-Reviewer: Piotr Kliczewski <>
Gerrit-Reviewer: gerrit-hooks <>
vdsm-patches mailing list

Reply via email to