File 0030-SAPInstance-implemeted-reload-method.patch of Package resource-agents.8843

From a1b4edaf11b3a50127979ce972445ff86ff247a7 Mon Sep 17 00:00:00 2001
From: Fabian Herschel <fabian.herschel@suse.com>
Date: Fri, 27 Jul 2018 12:33:19 +0200
Subject: [PATCH] SAPInstance: implemeted reload method The reload method is
 needed to avoid resource restarts after a non-unique parameter has been
 changed. This is in special for interest of the MONITOR_SERVICES parameter.
 Cherry-picked from 70a28e8130be863a9073b0a80e0511e971e205c4

---
 heartbeat/SAPInstance | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/heartbeat/SAPInstance b/heartbeat/SAPInstance
index be2ff305..cb8690ba 100755
--- a/heartbeat/SAPInstance
+++ b/heartbeat/SAPInstance
@@ -58,9 +58,10 @@ sapinstance_usage() {
 	The 'stop' operation stops the instance
 	The 'status' operation reports whether the instance is running
 	The 'monitor' operation reports whether the instance seems to be working
-        The 'promote' operation starts the primary instance in a Master/Slave configuration
-        The 'demote' operation stops the primary instance and starts the ERS instance
-        The 'notify' operation always returns SUCCESS
+	The 'promote' operation starts the primary instance in a Master/Slave configuration
+	The 'demote' operation stops the primary instance and starts the ERS instance
+    The 'reload' operation allows changed parameters (non-unique only) without restarting the service
+	The 'notify' operation always returns SUCCESS
 	The 'validate-all' operation reports whether the parameters are valid
 	The 'methods' operation reports on the methods $0 supports
 
@@ -206,6 +207,7 @@ The name of the SAP START profile. Specify this parameter, if you have changed t
 <action name="monitor" depth="0" timeout="60" interval="119" role="Master" />
 <action name="promote" timeout="320" />
 <action name="demote" timeout="320" />
+<action name="reload" timeout="320" />
 <action name="validate-all" timeout="5" />
 <action name="meta-data" timeout="5" />
 <action name="methods" timeout="5" />
@@ -226,6 +228,7 @@ sapinstance_methods() {
 	monitor
         promote
         demote
+    reload
         notify
 	validate-all
 	methods
@@ -938,6 +941,9 @@ case "$ACTION" in
                                           exit $?;;
   validate-all)                           sapinstance_validate
                                           exit $?;;
+  reload )
+                     ocf_log info "reloading SAPInstance parameters"
+                     exit $OCF_SUCCESS;;
   *)                                      sapinstance_methods
                                           exit $OCF_ERR_UNIMPLEMENTED;;
 esac
-- 
2.13.7

openSUSE Build Service is sponsored by