Script function: Processes ServiceManager actions, queue modifications and controls steps in a Zero Downtime Upgrade scenario.
General information
This script element can be used to handle three different types of tasks:
The actions that this script function takes depends on the parameters that are specified. Also refer to the syntax descriptions below.
You can only start server processes and agents using this script element if a ServiceManager is available that is correctly configured and connected to the AE system. Also refer to the descriptions of the settings for Agent objects and Server objects.
For a list of possible return codes see the bottom of this topic.
[ Queue ] [ ServiceManager ][ Zero Downtime Upgrade]
MODIFY_SYSTEM(Action, Queue, Value)
Syntax |
Description/Format |
---|---|
Action |
Defines the modifications that should be made in Queue objects. Allowed values: "MODE", "MAX_SLOTS" or "PRIORITY" |
Queue |
Name of the Queue object that should be changed. |
Value |
Value for the setting or status that should be changed (Action). Allowed values depending on the selected action: |
Changing the status of Queue objects (Start/Stop) using this script element (Action: MODE) has the effect that the new status is valid until a new modification is made. Modifications to priority or maximum queue slots remain valid until these values are changed due to an exception or if a user changes them manually.
The number of parallel running tasks is not limited if the maximum slots of Queue objects are changed to "UNLIMITED".
The following example sets the status of the Queue object "QUEUE.JOBS" to "GO":
:SET &RET# = MODIFY_SYSTEM("MODE", "QUEUE.JOBS", "GO")
:IF &RET# = "0"
: PRINT "Processing the Queue object QUEUE.JOBS has successfully been activated."
:ELSE
: PRINT "QUEUE.JOBS: Error when changing the status to GO."
:ENDIF
[ Queue ] [ ServiceManager ][ Zero Downtime Upgrade]
MODIFY_SYSTEM(Action, Name,[ Server mode])
Syntax |
Description/Format |
---|---|
Action |
Defines the action that should be taken for agents, server processes or the AE system. Allowed values: "STARTUP", "TERMINATE", "CHANGE_MODE", "DISCONNECT" or "SHUTDOWN" |
Name |
Name of the agent or server process that should be started/ended or whose mode should be changed. |
Server mode |
Mode to which the specified WP should be changed. This parameter is only required if the mode of a WP should be changed (Action = CHANGE_MODE). Allowed values: |
The script element MODIFY_SYSTEM can also be used to start or end server processes and agents or to change the mode of a server's work processes.
The action "STARTUP" can only be used if a ServiceManager is available and if the agent or server process to be started has correctly been configured. Also refer to the settings in the Attributes tab of Agent objects or Server objects.
In order to terminate the AE system using "SHUTDOWN", the value "UC4" is required for the parameter Name (see: :SHUTDOWN).
The parameter Server mode is required in order to change the mode of a Server's work process (Action: "CHANGE_MODE"). The parameter Server mode must not be used in combination with the actions "STARTUP", "TERMINATE", "DISCONNECT" and "SHUTDOWN".
Shutting down the agent "WIN01":
:SET &ACT# = MODIFY_SYSTEM("TERMINATE", "WIN01")
[ Queue ] [ ServiceManager ][ Zero Downtime Upgrade]
MODIFY_SYSTEM(Action, Value)
Syntax |
Description/Format |
---|---|
Action |
Allowed value "ZERO_DOWNTIME_UPGRADE" = Zero Downtime Upgrade control. The following Value parameter will be applied for routing messages to be processed by new or old WPs / CPs . |
Value |
Allowed values: "BEGIN" = sets UC_SYSTEM_SETTINGS / ZERO_DOWNTIME_UPGRADE to "Y" "END" = sets UC_SYSTEM_SETTINGS / ZERO_DOWNTIME_UPGRADE to "N" - only possible before taking any steps in the upgrade process "ROLLBACK" = Rollback mode. "FINALIZE" = Finalizes the Zero Downtime Upgrade phase by setting the currently active message queue set as base and resetting UC_SYSTEM_SETTINGS / ZERO_DOWNTIME_UPGRADE to "N" |
Usage for carrying out an upgrade with zero downtime only, when UC_SYSTEM_SETTINGS / ZERO_DOWNTIME_UPGRADE = Y
The databaseA database is an organized collection of data including relevant data structures. upgrade has to be processed successfully beforehand. At least one CP and one WP of the new version have to be up and running.
For details please refer to "Zero Downtime Upgrade - Upgrade Process".
This example shows the settings necessary for starting the rollback:
:SET &RET# = MODIFY_SYSTEM("ZERO_DOWNTIME_UPGRADE", "ROLLBACK")
List of Possible Return Codes:
Return codes |
---|
"0" - The action defined for this script function has successfully been processed. |
See also:
Script Element | Description |
---|---|
:SHUTDOWN | Ends an AE system. |
SYS_HOST_ALIVE | Checks if a particular host is active. |
SYS_SERVER_ALIVE | Checks if a certain server process is active. |
TOGGLE_SYSTEM_STATUS | Stops or starts the automatic processing of a complete client. |
Script Elements - Read or Modify Objects
Sample Collection
Notification with Variable Message Text
About Scripts
Script Elements - Alphabetical Listing
Script Elements - Ordered by Function