While developing the REST API I was having trouble using the
getAllTasks(Info|Statuses) API to get tasks information.  I found out that hsm
is hard-coding a tagged search for 'spm' in the calls to the task manager.  Is
there a reason that this tag must be hard-coded or can we remove it as in the
patch below?  With this patch applied I am able to list all tasks.

If this patch is acceptable, I would be happy to submit it to gerrit for
approval.  Thanks!

commit 72621b2ffe5a0a21ba1023dada36b405bf2111f2
Author: Adam Litke <a...@us.ibm.com>
Date:   Mon Apr 16 13:56:55 2012 -0500

    Don't hardcode the 'spm' tag when getting information for all tasks.

diff --git a/vdsm/storage/hsm.py b/vdsm/storage/hsm.py
index 2755aef..51ee17c 100644
--- a/vdsm/storage/hsm.py
+++ b/vdsm/storage/hsm.py
@@ -1694,7 +1694,7 @@ class HSM:
         :options: ?
-        allTasksStatus = self.taskMng.getAllTasksStatuses("spm")
+        allTasksStatus = self.taskMng.getAllTasksStatuses()
         return dict(allTasksStatus=allTasksStatus)
@@ -1733,7 +1733,7 @@ class HSM:
         # TODO: if spUUID passed, make sure tasks are relevant only to pool
-        allTasksInfo = self.taskMng.getAllTasksInfo("spm")
+        allTasksInfo = self.taskMng.getAllTasksInfo()
         return dict(allTasksInfo=allTasksInfo)

Adam Litke <a...@us.ibm.com>
IBM Linux Technology Center

vdsm-devel mailing list

Reply via email to