qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 0/2] qmp: implement readline handlig for stdio


From: Luiz Capitulino
Subject: Re: [Qemu-devel] [PATCH 0/2] qmp: implement readline handlig for stdio
Date: Thu, 31 May 2012 10:49:56 -0300

On Thu, 31 May 2012 10:10:07 +0200
Kevin Wolf <address@hidden> wrote:

> Am 30.05.2012 18:41, schrieb Luiz Capitulino:
> > On Wed, 30 May 2012 16:19:43 +0200
> > Kevin Wolf <address@hidden> wrote:
> > 
> >> Am 30.05.2012 12:01, schrieb Pavel Hrdina:
> >>> For debug it would be nice to have a same functionality for the qmp 
> >>> monitor
> >>> on stdio as the hmp monitor on stdio has. For this purpose we also use
> >>> readline mode for qmp monitor on stdio.
> >>>
> >>> Because we don't need anymore an echo function for stdio, there is also 
> >>> revert of
> >>> a commit, which added this functionality.
> >>
> >> Thanks, this will be really helpful when using QMP manually!
> > 
> > Except it adds a user feature down the QMP low-levels...
> 
> So it's implemented in the wrong layer?

Yes. I've talked with Pavel yesterday and suggested him that maybe this
could be implemented at the chardev layer.

> > What's the problem with using rlwrap as suggested here:
> > 
> >  http://wiki.qemu.org/QMP#By_hand
> 
> Is it a feature these days to annoy users?
> 
> Your link is a whole screen full of description what I need to do.

It shows different ways to talk to QMP. My preferred one is to use rlwrap.

For quick testing, my qemu config will always create a socket in a known
location and then I have an alias to run rlwrap. This takes nothing to do
and has all the features you're asking for.

> Seriously? The natural thing to do is -qmp stdio, and I don't read any
> wikis for that.
>
> It's nice that you can get some kind of usability by typing in long
> network addresses or path names and hacking a rlwrap around it (didn't
> know this one yet), but it's not stuff I want to deal with. It should
> just work.

I'm not opposed to having this somewhere else, but adding a crude hack down
QMP low-levels just to have readline support while the same functionality
can be achieved by using a simple tool doesn't make much sense to me.

Actually, rlwrap supports more features than our NIH readline implementation.

> > Or using/improving QMP shell?
> 
> It tries to abstract QMP away from me. If I didn't want QMP, I'd use the
> human monitor. Not sure if I can even get QMP shell to send a complex
> command like 'transaction' correctly.

Let's improve it if it doesn't.

> Anyway, even if QMP shell did what I wanted, I don't want to mess with
> starting up another program and typing in network addresses. qemu used
> to be simple to use, and that's what I liked about it.

You can use aliases. Let's not forget that we're talking about a machine
protocol vs. a user gui.




reply via email to

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