qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [libvirt] [Qemu-devel] Re: Libvirt debug API


From: Daniel P. Berrange
Subject: Re: [libvirt] [Qemu-devel] Re: Libvirt debug API
Date: Mon, 26 Apr 2010 16:20:39 +0100
User-agent: Mutt/1.4.1i

On Mon, Apr 26, 2010 at 10:08:33AM -0500, Anthony Liguori wrote:
> On 04/26/2010 09:54 AM, Daniel P. Berrange wrote:
> >On Mon, Apr 26, 2010 at 05:34:22PM +0300, Avi Kivity wrote:
> >   
> >>On 04/26/2010 05:25 PM, Chris Lalancette wrote:
> >>     
> >>>Right, and you are probably one of the users this work targets.  But in
> >>>general, for those not very familiar with virtualization/qemu, we want
> >>>to steer them far clear of this API.  That goes doubly true for 
> >>>application
> >>>developers; we want them to be able to use a stable, long-term API and
> >>>not have to worry about the nitty-gritty details of the monitor.  It's 
> >>>that
> >>>latter group that we want to make sure doesn't use this API.
> >>>
> >>>       
> >>With qmp, we have a stable long term API, and the nitty-gritty details
> >>are easily hidden behind a stock json parser (unfortunately some rpc
> >>details remain).  The command line is baroque, but the libvirt xml isn't
> >>so pretty either.
> >>
> >>The problem is a user that starts with libvirt and outgrows its
> >>featureset.  Do we want them to fall back to qmp?
> >>     
> >If were QMP were to be the standard mgmt API, then you are merely inverting
> >the problem. The problem is now a user that starts with QMP and outgrows
> >its featureset.
> >
> >We have two layers in the stack here&  neither provides a superset of the
> >other. As Anthony has mentioned, this has parallels with GTK (libvirt) vs
> >libX11 (libQMP). Programming against GTK does not give you all the features
> >you'd have if you programmed against X, but most people do not need them
> >and this is offset by the benefits GTK gives in portability across OS. GTK
> >does allow them to get direct access to X if really needed, but most apps
> >will avoid doing that if at all possible, and when it is found to be
> >neccessary new APIs are added to GTK so that direct X11 access remains a
> >short-term hack.
> >
> >We shouldn't have to frame this as a libvirt vs QMP problem. libvirt uses
> >QMP for its work, and apps use libvirt API for the vast majority of their
> >needs. If direct access to QMP is needed we can now provide that for apps
> >as a short term hack, until suitable APIs are added to libvirt.
> >   
> 
> I agree with you (for the most part).
> 
> The one difference here is that libgtk actually implements a full widget 
> kit on top of libX11.  That's why people use gtk and not X11 directly.  
> Portability was really an after thought with gtk.
>
> If you look at libgtk and libcairo, instead of trying to replicate the 
> features of cairo within gtk, gtk encourages people to use cairo 
> directly for anything beyond the simplest 2d operations.

For the sake of my analogy, I'd still group cairo in with gtk, not x11. It 
is really just a re-implmentation of the GDK drawing layer from GTK. It 
still provides a portable higher level abstraction over underlying graphics
& rendering systems it supports. eg, again an app might do the majority of
its drawing with Cairo, but occasionally need to jump outside to use XRender
or OpenGL directly for pieces that aren't supported currently in the cairo
API.

Regards,
Daniel
-- 
|: Red Hat, Engineering, London    -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://deltacloud.org :|
|: http://autobuild.org        -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|




reply via email to

[Prev in Thread] Current Thread [Next in Thread]