From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Lrxox-0004TS-1x for qemu-devel@nongnu.org; Thu, 09 Apr 2009 13:13:47 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Lrxos-0004Qf-TW for qemu-devel@nongnu.org; Thu, 09 Apr 2009 13:13:46 -0400 Received: from [199.232.76.173] (port=44611 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Lrxos-0004QQ-Nw for qemu-devel@nongnu.org; Thu, 09 Apr 2009 13:13:42 -0400 Received: from mail2.shareable.org ([80.68.89.115]:49333) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Lrxos-0001ev-C9 for qemu-devel@nongnu.org; Thu, 09 Apr 2009 13:13:42 -0400 Date: Thu, 9 Apr 2009 18:13:41 +0100 From: Jamie Lokier Subject: Re: [Qemu-devel] Re: [libvirt] Re: [PATCH 2/3] Introduce monitor 'wait' command Message-ID: <20090409171341.GE14196@shareable.org> References: <1239200204-4934-1-git-send-email-aliguori@us.ibm.com> <1239200204-4934-2-git-send-email-aliguori@us.ibm.com> <20090408143335.GS18076@redhat.com> <49DCBCBE.6010102@redhat.com> <49DCE266.9080809@us.ibm.com> <20090408190611.GC10947@shareable.org> <20090409095511.GE18054@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20090409095511.GE18054@redhat.com> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Daniel P. Berrange" Cc: libvir-list@redhat.com, Jan Kiszka , qemu-devel@nongnu.org, Hollis Blanchard Daniel P. Berrange wrote: > One scheme would be to have a small buffer - enough to store say 10 events. > If the monitor is blocking for write, and the buffer is full then start to > discard all further events. When the buffer has more space again, then > send an explicit 'overflow' event informing the app that stuff has been > dropped from the event queue. > > In normal circumstances the app would never see this message, but if there > was some unexpected problem causing the app to not process events quickly > enough, then at least it would be able to then detect that qemu has > discarded alot of events, and re-synchronize its state by running appropriate > 'info' commands. This is pretty much what Linux real-time queued I/O signals do. It's ugly but works. :-) -- Jamie