From 090377807b5214b3ae4a6bfe294d94df3eb5d6df Mon Sep 17 00:00:00 2001 From: Michael Hanselmann <hansmi@google.com> Date: Wed, 22 Feb 2012 12:58:05 +0100 Subject: [PATCH] =?UTF-8?q?Remove=20deprecated=20=E2=80=9CQueryLocks?= =?UTF-8?q?=E2=80=9D=20LUXI=20request?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This has been deprecated since Ganeti 2.4 and hasn't been used by Ganeti's code since. I'm not aware of any external users. Signed-off-by: Michael Hanselmann <hansmi@google.com> Reviewed-by: Iustin Pop <iustin@google.com> --- NEWS | 2 ++ lib/luxi.py | 7 ------- lib/server/masterd.py | 7 ------- 3 files changed, 2 insertions(+), 14 deletions(-) diff --git a/NEWS b/NEWS index 7a4876371..10980fc22 100644 --- a/NEWS +++ b/NEWS @@ -12,6 +12,8 @@ Version 2.6.0 beta1 - Replaced ``--disks`` option of ``gnt-instance replace-disks`` with a more flexible ``--disk`` option. Now disk size and mode can be changed upon recreation. +- Removed deprecated ``QueryLocks`` LUXI request. Use + ``Query(what=QR_LOCK, ...)`` instead. Version 2.5.0 rc5 diff --git a/lib/luxi.py b/lib/luxi.py index bfebbc1e5..4ea89de8d 100644 --- a/lib/luxi.py +++ b/lib/luxi.py @@ -34,7 +34,6 @@ import collections import time import errno import logging -import warnings from ganeti import serializer from ganeti import constants @@ -65,7 +64,6 @@ REQ_QUERY_EXPORTS = "QueryExports" REQ_QUERY_CONFIG_VALUES = "QueryConfigValues" REQ_QUERY_CLUSTER_INFO = "QueryClusterInfo" REQ_QUERY_TAGS = "QueryTags" -REQ_QUERY_LOCKS = "QueryLocks" REQ_QUEUE_SET_DRAIN_FLAG = "SetDrainFlag" REQ_SET_WATCHER_PAUSE = "SetWatcherPause" @@ -551,8 +549,3 @@ class Client(object): def QueryTags(self, kind, name): return self.CallMethod(REQ_QUERY_TAGS, (kind, name)) - - def QueryLocks(self, fields, sync): - warnings.warn("This LUXI call is deprecated and will be removed, use" - " Query(\"%s\", ...) instead" % constants.QR_LOCK) - return self.CallMethod(REQ_QUERY_LOCKS, (fields, sync)) diff --git a/lib/server/masterd.py b/lib/server/masterd.py index 41df24ede..23dff6829 100644 --- a/lib/server/masterd.py +++ b/lib/server/masterd.py @@ -393,13 +393,6 @@ class ClientOps: op = opcodes.OpTagsGet(kind=kind, name=name) return self._Query(op) - elif method == luxi.REQ_QUERY_LOCKS: - (fields, sync) = args - logging.info("Received locks query request") - if sync: - raise NotImplementedError("Synchronous queries are not implemented") - return self.server.context.glm.OldStyleQueryLocks(fields) - elif method == luxi.REQ_QUEUE_SET_DRAIN_FLAG: (drain_flag, ) = args logging.info("Received queue drain flag change request to %s", -- GitLab