From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51064) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YY8Sd-0000nM-Dr for qemu-devel@nongnu.org; Wed, 18 Mar 2015 03:32:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YY8Sa-0002yW-8S for qemu-devel@nongnu.org; Wed, 18 Mar 2015 03:32:15 -0400 Received: from mail-we0-x235.google.com ([2a00:1450:400c:c03::235]:34997) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YY8Sa-0002yC-1x for qemu-devel@nongnu.org; Wed, 18 Mar 2015 03:32:12 -0400 Received: by webcq43 with SMTP id cq43so25109479web.2 for ; Wed, 18 Mar 2015 00:32:09 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <550929F5.5020500@redhat.com> Date: Wed, 18 Mar 2015 08:32:05 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <20150317190836.GP6540@redhat.com> In-Reply-To: <20150317190836.GP6540@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Subject: Re: [Qemu-devel] RFC: -object vs -chardev creation order List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Daniel P. Berrange" , qemu-devel On 17/03/2015 20:08, Daniel P. Berrange wrote: > A third option is to not process -object args in one go, instead process > each type of object at a time. eg we'd first create all the > -object tls-credential instances, then create the -chardev instances, > then create the -object rng-egd instances. This is probably the least > amount of work in short term, but not all that scalable, unless we do > a catch-all default case, so we only need code up hacks for a few > particular object types. > > Thus my gut feeling is to do option 3, but I'd like other opinions before > embarking on this.... Yes, for now it is the best. Another idea is to build objects lazily. This requires adding a "missing property" interface and making /objects implement it. We can think about it later. Paolo