Received: from eggs.gnu.org ([2001:4830:134:3::10]:37613) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bpiQ9-0003BM-EX for qemu-devel@nongnu.org; Thu, 29 Sep 2016 16:59:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bpiQ7-00006M-L6 for qemu-devel@nongnu.org; Thu, 29 Sep 2016 16:59:08 -0400 References: <1470683381-16680-1-git-send-email-jsnow@redhat.com> <57E94491.8090501@virtuozzo.com> <57EBB4A1.1000104@virtuozzo.com> <20160929113307.GJ5742@noname.redhat.com> From: John Snow Message-ID: Date: Thu, 29 Sep 2016 16:58:57 -0400 MIME-Version: 1.0 In-Reply-To: <20160929113307.GJ5742@noname.redhat.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [Qemu-block] [PATCH 0/5] blockjobs: Fix transactional race condition List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf , Vladimir Sementsov-Ogievskiy Cc: qemu-devel , Stefan Hajnoczi , Jeff Cody , "Denis V. Lunev" , qemu block On 09/29/2016 07:33 AM, Kevin Wolf wrote: > Am 28.09.2016 um 14:16 hat Vladimir Sementsov-Ogievskiy geschrieben: >>> I think jobs will need to remain "one coroutine, one job" for now, >>> but there's no reason why drive-backup or blockdev-backup can't >>> just create multiple jobs each if that's what they need to do. >>> (The backup job object could, in theory, just have another job >>> pointer to a helper job if it really became necessary.) > > What's the problem with a job spawning additional coroutines internally? > Jobs already do this all the time (AIO requests are just coroutines in > disguise.) > Mostly I was just pushing back against baking in multi-coroutines per-job as a default. If you want to add them in your own extensions, e.g. MultiJob : BlockJob { Coroutine *extra; } then I'm okay with that and realize we already do exactly that. Beyond that I think complicates the job layer a little more than necessary... but maybe I am being too pre-fearful. > A job is basically just the user interface for managing a background > process, so helper jobs that are managed internally rather than by the > user don't seem to make that much sense. > > Kevin >