diff --git a/lib/rpc.py b/lib/rpc.py index 136532ff5a290880c0e3b8abfa92a84723a1b3cf..f1a470e3087d394a6c49984153078f03e5d64512 100644 --- a/lib/rpc.py +++ b/lib/rpc.py @@ -661,7 +661,7 @@ class RpcRunner(_RpcClientBase, encoders.update({ # Encoders requiring configuration object rpc_defs.ED_INST_DICT: self._InstDict, - rpc_defs.ED_INST_DICT_HVP_BEP: self._InstDictHvpBep, + rpc_defs.ED_INST_DICT_HVP_BEP_DP: self._InstDictHvpBepDp, rpc_defs.ED_INST_DICT_OSP_DP: self._InstDictOspDp, # Encoders annotating disk parameters @@ -722,9 +722,10 @@ class RpcRunner(_RpcClientBase, nic["nicparams"] = objects.FillDict( cluster.nicparams[constants.PP_DEFAULT], nic["nicparams"]) + idict["disks"] = self._DisksDictDP((instance.disks, instance)) return idict - def _InstDictHvpBep(self, (instance, hvp, bep)): + def _InstDictHvpBepDp(self, (instance, hvp, bep)): """Wrapper for L{_InstDict}. """ diff --git a/lib/rpc_defs.py b/lib/rpc_defs.py index 2e8841b430261b94344ffbdec54ab2b293415efa..233fce554580376cda0d4f83d93a9138ce815527 100644 --- a/lib/rpc_defs.py +++ b/lib/rpc_defs.py @@ -64,7 +64,7 @@ ACCEPT_OFFLINE_NODE = object() (ED_OBJECT_DICT, ED_OBJECT_DICT_LIST, ED_INST_DICT, - ED_INST_DICT_HVP_BEP, + ED_INST_DICT_HVP_BEP_DP, ED_NODE_TO_DISK_DICT, ED_INST_DICT_OSP_DP, ED_IMPEXP_IO, @@ -266,7 +266,7 @@ _INSTANCE_CALLS = [ ("instance", ED_INST_DICT, "Instance object"), ], None, _MigrationStatusPostProc, "Report migration status"), ("instance_start", SINGLE, None, TMO_NORMAL, [ - ("instance_hvp_bep", ED_INST_DICT_HVP_BEP, None), + ("instance_hvp_bep", ED_INST_DICT_HVP_BEP_DP, None), ("startup_paused", None, None), ], None, None, "Starts an instance"), ("instance_os_add", SINGLE, None, TMO_1DAY, [