Re: [Qemu-devel] [RFC 1/3] qemu-agent: add guest-network-set-interface command

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

 



On 05/21/2015 07:52 AM, Olga Krishtal wrote:
> On 17/04/15 11:53, Chen Fan wrote:
>> Nowadays, qemu has supported physical NIC hotplug for high network
>> throughput. but it's in conflict with live migration feature, to keep
>> network connectivity, we could to create bond device interface which
>> provides a mechanism for enslaving multiple network interfaces into a
>> single "bond" interface. the active-backup mode can be used for an
>> automatic switch. so this patch is adding a guest-network-set-interface
>> command for creating bond device. so the management can easy to create
>> a bond device dynamically when guest running.
>>
>> Signed-off-by: Chen Fan <chen.fan.fnst@xxxxxxxxxxxxxx>
>> ---

>> @@ -588,6 +626,22 @@
>>     'returns': ['GuestNetworkInterface'] }
>>     ##
>> +# @guest-network-set-interface:
>> +#
>> +# Set guest network interface
>> +#
>> +# return: 0:      call successful.
>> +#
>> +#         -1:     call failed.
>> +#
>> +#
>> +# Since: 2.3

You've missed 2.3; if we still want this, it will need to be updated to 2.4.

>> +##
>> +{ 'command': 'guest-network-set-interface',
>> +  'data'   : {'interface': 'GuestNetworkInterface2' },
>> +  'returns': 'int' }
> I thought that usage of built-in types as the returning value is
> deprecated.
> Lets return dictionary in guest-network-set (get)-interface

Correct. Returning a non-dictionary now causes the generator to barf if
you don't update a whitelist.  But you don't even need a return value -
QGA is already set up to return {} on success and an error message on
failure, if you have nothing further to add.  Just omit 'returns' from
your 'command' definition.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]