On 10/11/2016 03:15 PM, Marko Myllynen wrote:
> Hi,
> I see that recently the last-update field has been added to the balloon
> statistics, this is how it looks like from Python:
> [(<libvirt.virDomain object at 0x7fb45b7faa50>, {'balloon.rss': 960048L,
> 'balloon.swap_in': 0L, 'balloon.usable': 1676424L, 'balloon.unused':
> 1376188L, 'balloon.major_fault': 816L, 'balloon.swap_out': 0L,
> 'balloon.current': 2097152L, 'balloon.maximum': 2097152L,
> 'balloon.available': 2048364L, 'balloon.minor_fault': 460160L,
> 'balloon.last-update': 1476213030L})]
> As you can see, there's an inconsistency as all the other members use
> underscore (_), not dash (-). This actually matters with the PCP plugin
> since PCP metric names can contain _ but not -.

Looks like it was actually added as an output in 2.1.0


There were continued adjustments:

commit id: f57fbd6c4a5dfc8e725f036791e6333d1ab6f04e
commit id: 438c204763f7d8eed79554075f5633545a4a5df1

Since this is output only and we're not setting it for input, it's
almost too bad we cannot treat this as a spelling error and change it. I
tried looking through history for other cross version instances of
changing output, but didn't find any. Closest I could come was the
blkiotune parameters which can take both _ and - for their names, but
display _ in the name.

> Now that last-update is part of the API in 2.3 I guess it's too late to
> change this but it would nice if in the future the member names could be
> kept consistent and underscore used for new members, as it has been so far.

Hard to be always vigilant... even harder when input parameters prefer
the dash model (see blkdeviotune for example). Sometimes things slip
through the cracks though.


libvir-list mailing list

Reply via email to