Revision e1530b10 lib/rapi/rlib2.py
b/lib/rapi/rlib2.py | ||
---|---|---|
707 | 707 |
def _ParseInstanceCreateRequestVersion1(data, dry_run): |
708 | 708 |
"""Parses an instance creation request version 1. |
709 | 709 |
|
710 |
@rtype: L{opcodes.OpCreateInstance}
|
|
710 |
@rtype: L{opcodes.OpInstanceCreate}
|
|
711 | 711 |
@return: Instance creation opcode |
712 | 712 |
|
713 | 713 |
""" |
... | ... | |
769 | 769 |
beparams = baserlib.CheckParameter(data, "beparams", default={}) |
770 | 770 |
utils.ForceDictType(beparams, constants.BES_PARAMETER_TYPES) |
771 | 771 |
|
772 |
return opcodes.OpCreateInstance(
|
|
772 |
return opcodes.OpInstanceCreate(
|
|
773 | 773 |
mode=baserlib.CheckParameter(data, "mode"), |
774 | 774 |
instance_name=baserlib.CheckParameter(data, "name"), |
775 | 775 |
os_type=baserlib.CheckParameter(data, "os"), |
... | ... | |
831 | 831 |
|
832 | 832 |
Request data version 0 is deprecated and should not be used anymore. |
833 | 833 |
|
834 |
@rtype: L{opcodes.OpCreateInstance}
|
|
834 |
@rtype: L{opcodes.OpInstanceCreate}
|
|
835 | 835 |
@return: Instance creation opcode |
836 | 836 |
|
837 | 837 |
""" |
... | ... | |
865 | 865 |
nics[0]["bridge"] = fn("bridge") |
866 | 866 |
|
867 | 867 |
# Do not modify anymore, request data version 0 is deprecated |
868 |
return opcodes.OpCreateInstance(
|
|
868 |
return opcodes.OpInstanceCreate(
|
|
869 | 869 |
mode=constants.INSTANCE_CREATE, |
870 | 870 |
instance_name=fn('name'), |
871 | 871 |
disks=disks, |
Also available in: Unified diff