All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Snow <jsnow@redhat.com>
To: qemu-devel@nongnu.org, qemu-block@nongnu.org
Cc: jtc@redhat.com, Max Reitz <mreitz@redhat.com>,
	Kevin Wolf <kwolf@redhat.com>,
	Markus Armbruster <armbru@redhat.com>,
	"Dr. David Alan Gilbert" <dgilbert@redhat.com>,
	Eric Blake <eblake@redhat.com>, Jeff Cody <jcody@redhat.com>,
	John Snow <jsnow@redhat.com>
Subject: [Qemu-devel] [PATCH v3 00/15] jobs: Job Exit Refactoring Pt 2
Date: Fri, 31 Aug 2018 18:28:52 -0400	[thread overview]
Message-ID: <20180831222907.16257-1-jsnow@redhat.com> (raw)

This is part two of a two part series that refactors the exit logic
of jobs.

This series forces all jobs to use the "finalize" semantics that were
introduced previously, but only exposed via the backup jobs.

Patches 1-3 add plumbing for the auto-dismiss and auto-finalize flags
but do not expose these via QAPI/QMP.

Patches 4-7 refactor the .exit() callbacks into the component pieces
of .prepare(), .commit(), .abort() and .clean(). Except mirror, which
I cheat with.

Patches 8-10 remove the last usages of .exit in a test.
Patche 11 removes the .exit callback and the machinery to invoke it.

Patches 12-14 expose the new QMP options to all of the jobs.
Patch 15 is a doc fixup.

====
"V3"
====

001/15:[----] [--] 'block/commit: add block job creation flags'
002/15:[----] [--] 'block/mirror: add block job creation flags'
003/15:[----] [--] 'block/stream: add block job creation flags'
004/15:[0006] [FC] 'block/commit: refactor commit to use job callbacks'
005/15:[down] 'block/mirror: don't install backing chain on abort'
006/15:[0011] [FC] 'block/mirror: conservative mirror_exit refactor'
007/15:[----] [--] 'block/commit: refactor stream to use job callbacks'
008/15:[----] [--] 'tests/blockjob: replace Blockjob with Job'
009/15:[----] [--] 'tests/test-blockjob: remove exit callback'
010/15:[down] 'tests/test-blockjob-txn: move .exit to .clean'
011/15:[0004] [FC] 'jobs: remove .exit callback'
012/15:[----] [--] 'qapi/block-commit: expose new job properties'
013/15:[----] [--] 'qapi/block-mirror: expose new job properties'
014/15:[----] [--] 'qapi/block-stream: expose new job properties'
015/15:[----] [--] 'block/backup: qapi documentation fixup'

000: Fixed my cover letter subject. Phew!
004: Adjusted comment, added R-B
005: New; based on discussions from what is now 006 (was 005)
006: mirror_exit_common returns ret == 0 if we are aborting
     and it aborts successfully (Max)
     Added assertion that we aborted successfully (Max)
010: New, minor cleanup before we can actually remove .exit.
011: Removed what's now patch 10, added R-B per Max's comment.

=====
"V2":
=====
 - Split off the first part of the series to Pt.1
 - More aggressively refactored .commit()
 - Went all the way to deleting .exit() callback (Kevin)

John Snow (15):
  block/commit: add block job creation flags
  block/mirror: add block job creation flags
  block/stream: add block job creation flags
  block/commit: refactor commit to use job callbacks
  block/mirror: don't install backing chain on abort
  block/mirror: conservative mirror_exit refactor
  block/commit: refactor stream to use job callbacks
  tests/blockjob: replace Blockjob with Job
  tests/test-blockjob: remove exit callback
  tests/test-blockjob-txn: move .exit to .clean
  jobs: remove .exit callback
  qapi/block-commit: expose new job properties
  qapi/block-mirror: expose new job properties
  qapi/block-stream: expose new job properties
  block/backup: qapi documentation fixup

 block/commit.c            |  95 +++++++++++++++++++++-----------------
 block/mirror.c            |  63 ++++++++++++++++---------
 block/stream.c            |  28 ++++++++----
 blockdev.c                |  44 ++++++++++++++++--
 hmp.c                     |   5 +-
 include/block/block_int.h |  15 ++++--
 include/qemu/job.h        |  11 -----
 job.c                     |  77 ++++++++++++++-----------------
 qapi/block-core.json      |  80 +++++++++++++++++++++++++++-----
 tests/test-blockjob-txn.c |   4 +-
 tests/test-blockjob.c     | 114 +++++++++++++++++++++++-----------------------
 11 files changed, 326 insertions(+), 210 deletions(-)

-- 
2.14.4

             reply	other threads:[~2018-08-31 22:35 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-31 22:28 John Snow [this message]
2018-08-31 22:28 ` [Qemu-devel] [PATCH v3 01/15] block/commit: add block job creation flags John Snow
2018-09-01  3:17   ` Jeff Cody
2018-08-31 22:28 ` [Qemu-devel] [PATCH v3 02/15] block/mirror: " John Snow
2018-09-01  3:31   ` Jeff Cody
2018-08-31 22:28 ` [Qemu-devel] [PATCH v3 03/15] block/stream: " John Snow
2018-08-31 22:34   ` Eric Blake
2018-09-01  3:33   ` Jeff Cody
2018-08-31 22:28 ` [Qemu-devel] [PATCH v3 04/15] block/commit: refactor commit to use job callbacks John Snow
2018-08-31 22:28 ` [Qemu-devel] [PATCH v3 05/15] block/mirror: don't install backing chain on abort John Snow
2018-09-03  9:24   ` Max Reitz
2018-09-04 19:15     ` John Snow
2018-09-04 19:30       ` Eric Blake
2018-09-04 20:10         ` John Snow
2018-09-05  9:54         ` Kevin Wolf
2018-09-05 12:59           ` John Snow
2018-08-31 22:28 ` [Qemu-devel] [PATCH v3 06/15] block/mirror: conservative mirror_exit refactor John Snow
2018-09-03  9:32   ` Max Reitz
2018-09-04 16:17     ` John Snow
2018-08-31 22:28 ` [Qemu-devel] [PATCH v3 07/15] block/commit: refactor stream to use job callbacks John Snow
2018-09-03  9:33   ` Max Reitz
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 08/15] tests/blockjob: replace Blockjob with Job John Snow
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 09/15] tests/test-blockjob: remove exit callback John Snow
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 10/15] tests/test-blockjob-txn: move .exit to .clean John Snow
2018-09-03  9:41   ` Max Reitz
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 11/15] jobs: remove .exit callback John Snow
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 12/15] qapi/block-commit: expose new job properties John Snow
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 13/15] qapi/block-mirror: " John Snow
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 14/15] qapi/block-stream: " John Snow
2018-08-31 22:29 ` [Qemu-devel] [PATCH v3 15/15] block/backup: qapi documentation fixup John Snow

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180831222907.16257-1-jsnow@redhat.com \
    --to=jsnow@redhat.com \
    --cc=armbru@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=eblake@redhat.com \
    --cc=jcody@redhat.com \
    --cc=jtc@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.