Piotr Kliczewski has uploaded a new change for review.

Change subject: getVMList: introducing short parameter
......................................................................

getVMList: introducing short parameter

Due to vdsm sending only an array of vmids in a response to getVMList
the engine asks separately using VM.getStats which creates unnecessery
load. We need to make sure that for newer engines vdsm sends map of
vmids and status and for older engines an array as it was before. In
order to atchive it we introduce new parameter 'short' for getVMList
which is ignored by older vdsms and it makes sure that newer vdsms send
a map which fixes performance issue.


Change-Id: I51dea68e89a2c1685d16ba1921e1373eeb721860
Signed-off-by: pkliczewski <piotr.kliczew...@gmail.com>
Bug-Url: https://bugzilla.redhat.com/1198248
---
M 
backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/48/38448/1

diff --git 
a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java
 
b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java
index 4a3fab7..702e69b 100644
--- 
a/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java
+++ 
b/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/jsonrpc/JsonRpcVdsServer.java
@@ -159,7 +159,7 @@
     public VMListReturnForXmlRpc list() {
         JsonRpcRequest request =
                 new 
RequestBuilder("Host.getVMList").withOptionalParameterAsList("vmList",
-                        new ArrayList<String>(Arrays.asList(new String[] 
{}))).build();
+                        new ArrayList<String>(Arrays.asList(new String[] 
{}))).withParameter("short", false).build();
         Map<String, Object> response =
                 new FutureMap(this.client, request).withResponseKey("vmList")
                         .withResponseType(Object[].class);


-- 
To view, visit https://gerrit.ovirt.org/38448
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I51dea68e89a2c1685d16ba1921e1373eeb721860
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-3.5.2
Gerrit-Owner: Piotr Kliczewski <piotr.kliczew...@gmail.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to