rapi: make tags query not use jobs
authorIustin Pop <iustin@google.com>
Mon, 25 May 2009 08:59:37 +0000 (10:59 +0200)
committerIustin Pop <iustin@google.com>
Mon, 25 May 2009 09:14:10 +0000 (11:14 +0200)
commit25e39bfaec1ce1292f77c4d9b08a49cd1ae904fd
tree1b1d0241c35126eb744bb1165c0589d744eb6d51
parentd27776f046225736cf2f7ea06f0d33cc807cc65d
rapi: make tags query not use jobs

Currently the rapi tags query implementation is similar to the command
line one: it submits OpGetTags jobs. This not good, since this being an
API it can be used a lot and can pollute the job queue with many such
trivial jobs.

This patch converts it to use either queries (for nodes/instances) or
direct read from ssconf (for the cluster case). For ssconf, we added a
function to the ssconf.SimpleStore class for reading the tags.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
lib/rapi/baserlib.py
lib/ssconf.py