From 90ab1a95aca60207fcffff9c34bf4bd2487071b3 Mon Sep 17 00:00:00 2001
From: Iustin Pop <iustin@google.com>
Date: Sat, 15 Jan 2011 12:57:45 +0100
Subject: [PATCH] Rename OpRebootInstance and LURebootInstance
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: RenΓ© Nussbaumer <rn@google.com>
---
 lib/client/gnt_instance.py | 2 +-
 lib/cmdlib.py              | 2 +-
 lib/opcodes.py             | 2 +-
 lib/rapi/rlib2.py          | 2 +-
 tools/burnin               | 2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/lib/client/gnt_instance.py b/lib/client/gnt_instance.py
index 9c97aac04..2d2fbbc55 100644
--- a/lib/client/gnt_instance.py
+++ b/lib/client/gnt_instance.py
@@ -701,7 +701,7 @@ def _RebootInstance(name, opts):
   @return: the opcode needed for the operation
 
   """
-  return opcodes.OpRebootInstance(instance_name=name,
+  return opcodes.OpInstanceReboot(instance_name=name,
                                   reboot_type=opts.reboot_type,
                                   ignore_secondaries=opts.ignore_secondaries,
                                   shutdown_timeout=opts.shutdown_timeout)
diff --git a/lib/cmdlib.py b/lib/cmdlib.py
index d6a9254c5..9d22779b0 100644
--- a/lib/cmdlib.py
+++ b/lib/cmdlib.py
@@ -5049,7 +5049,7 @@ class LUStartupInstance(LogicalUnit):
         raise errors.OpExecError("Could not start instance: %s" % msg)
 
 
-class LURebootInstance(LogicalUnit):
+class LUInstanceReboot(LogicalUnit):
   """Reboot an instance.
 
   """
diff --git a/lib/opcodes.py b/lib/opcodes.py
index 7a0dd7c6c..2239f8157 100644
--- a/lib/opcodes.py
+++ b/lib/opcodes.py
@@ -849,7 +849,7 @@ class OpShutdownInstance(OpCode):
     ]
 
 
-class OpRebootInstance(OpCode):
+class OpInstanceReboot(OpCode):
   """Reboot an instance."""
   OP_ID = "OP_INSTANCE_REBOOT"
   OP_DSC_FIELD = "instance_name"
diff --git a/lib/rapi/rlib2.py b/lib/rapi/rlib2.py
index 98dc70f02..f06cbc87e 100644
--- a/lib/rapi/rlib2.py
+++ b/lib/rapi/rlib2.py
@@ -972,7 +972,7 @@ class R_2_instances_name_reboot(baserlib.R_Generic):
     reboot_type = self.queryargs.get('type',
                                      [constants.INSTANCE_REBOOT_HARD])[0]
     ignore_secondaries = bool(self._checkIntVariable('ignore_secondaries'))
-    op = opcodes.OpRebootInstance(instance_name=instance_name,
+    op = opcodes.OpInstanceReboot(instance_name=instance_name,
                                   reboot_type=reboot_type,
                                   ignore_secondaries=ignore_secondaries,
                                   dry_run=bool(self.dryRun()))
diff --git a/tools/burnin b/tools/burnin
index 4afef8d90..611a7b953 100755
--- a/tools/burnin
+++ b/tools/burnin
@@ -832,7 +832,7 @@ class Burner(object):
       Log("instance %s", instance, indent=1)
       ops = []
       for reboot_type in self.opts.reboot_types:
-        op = opcodes.OpRebootInstance(instance_name=instance,
+        op = opcodes.OpInstanceReboot(instance_name=instance,
                                       reboot_type=reboot_type,
                                       ignore_secondaries=False)
         Log("reboot with type '%s'", reboot_type, indent=2)
-- 
GitLab