28 lines
1.1 KiB
Diff
28 lines
1.1 KiB
Diff
|
# HG changeset patch
|
||
|
# User kfraser@localhost.localdomain
|
||
|
# Date 1181730493 -3600
|
||
|
# Node ID b643179d7452a91cd874ee713c78bf30f8df3d2d
|
||
|
# Parent ffdbe8aebde21710deca4ae84bba95e38f4b089b
|
||
|
xenapi: Implement VM.set_VCPUs_at_startup and VM.set_VCPUs_max XenAPI
|
||
|
methods in xend.
|
||
|
|
||
|
Signed-off-by: Jim Fehlig <jfehlig@novell.com>
|
||
|
|
||
|
Index: xen-3.1-testing/tools/python/xen/xend/XendAPI.py
|
||
|
===================================================================
|
||
|
--- xen-3.1-testing.orig/tools/python/xen/xend/XendAPI.py
|
||
|
+++ xen-3.1-testing/tools/python/xen/xend/XendAPI.py
|
||
|
@@ -1474,6 +1474,12 @@ class XendAPI(object):
|
||
|
else:
|
||
|
return xen_api_success_void()
|
||
|
|
||
|
+ def VM_set_VCPUs_at_startup(self, session, vm_ref, num):
|
||
|
+ return self.VM_set('VCPUs_at_startup', session, vm_ref, num)
|
||
|
+
|
||
|
+ def VM_set_VCPUs_max(self, session, vm_ref, num):
|
||
|
+ return self.VM_set('VCPUs_max', session, vm_ref, num)
|
||
|
+
|
||
|
def VM_set_actions_after_shutdown(self, session, vm_ref, action):
|
||
|
if action not in XEN_API_ON_NORMAL_EXIT:
|
||
|
return xen_api_error(['VM_ON_NORMAL_EXIT_INVALID', vm_ref])
|