# Update Commands

Update commands include DISABLE, ENABLE, RECOVER, REFRESH|REFR, and SUSPEND commands.

## DISABLE Command

The DISABLE command instructs the Substation ES transformer to stop an individual recipe or trigger. Subsequently, no processing can be performed against that recipe or trigger.

The DISABLE commands are used in the following ways:

`DISABLE,RECIPE|RID=name[,FOR=BES-Name,INTF|IID=intf-id]`
  This command disables an active Substation ES recipe. The RECIPE keyword specifies the name of the recipe to be disabled. The optional keyword FOR=BES-Name is used to filter the recipes selected for a BES or Alt-BES that is equal to `BES-Name`. The optional keyword `INTF|IID=intf-id` specifies an ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command Entered 'DISABLE,RID='SXC-IVP-C-DPL''
      SXT5838I The following recipe/trigger is disabled Intf:IIXFR,
               RID:SXC-IVP-C-DPL

`DISABLE,RECIPE|RID=*,FOR=BES-Name[,INTF|IID=intf-id]`
  This command disables the active Substation ES recipes. The keyword `FOR=BES-Name` is used to filter the recipes selected for BES or Alt-BES that is equal to `BES-Name`. The optional keyword `INTF|IID=intf-id` specifies an ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command 'DISABLE,RID=*,FOR=CICS1'
      SXT5838I IId:ESB01 Service is Disable, RID:DPL-BYTES

`DISABLE,TRIGGER|TID=name[,INTF|IID=intf-id]`
  This command disables an active Substation ES trigger. The `TRIGGER` keyword specifies the name of the trigger to be disabled. The optional keyword `INTF|IID=intf-id` specifies an ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command Entered 'DISABLE,TID='SXC-IVP-TRIGGER''
      SXT5838I The following recipe/trigger is disabled Intf:IIXFR,
               TID:SXC-IVP-TRIGGER

## ENABLE Command

The ENABLE command instructs the Substation ES transformer to start a recipe or trigger.

The ENABLE commands are used in the following ways:

`ENABLE,RECIPE|RID=name[,FOR=BES-Name,INTF|IID=intf-id]`
  This command enables a Substation ES recipe that is disabled. The `RECIPE` keyword specifies the name of the recipe to be enabled. The optional keyword `FOR=BES-Name` is used to filter the recipes selected for BES or Alt-BES that is equal to `BES-Name`. The optional keyword `INTF|IID=intf-id` specifies an ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command 'ENABLE,RID=SXC-DPL-C,FOR=CICS2'
      SXT5686W IId:ESB01 No Service Recipes found
      SXT5005I IId:ESB02 Recipe SXC-DPL-C has trace=5
      SXT5838I IId:ESB02 Service is Enabled, RID:SXC-DPL-C

`ENABLE,RECIPE|RID=*,FOR=BES-Name[,INTF|IID=intf-id]`
  This command enables all Substation ES recipes that are disabled. The keyword `FOR=BES-Name` is used to filter the recipes selected for BES or Alt-BES that is equal to `BES-Name`. The optional keyword `INTF|IID=intf-id` specifies an ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command 'ENABLE,RID=*,FOR=CICS1'
      SXT5005I IId:ESB01 Recipe DPL-BYTES has trace=5
      SXT5838I IId:ESB01 Service is Enable, RID:DPL-BYTES
      SXT5005I IId:ESB01 Recipe SXC-DPL-C has trace=5
      SXT5838I IId:ESB01 Service is Enabled, RID:SXC-DPL-C

`ENABLE,SUSPENDED [,FOR=BES-Name, INTF|IID=intf-id]`
  This command enables a Substation ES recipe service that is suspended. The `FOR` keyword is optional, and the `BES-Name` keyword is used to filter the recipes selected only for BES or Alt-BES that is equal to `BES-Name`.
  The `INTF|IID=intf-id` keyword denotes an ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command 'ENABLE,SUSPENDED'
      SXT5838I Service is unsuspended, RID:SXC-DPL-C

`ENABLE,TRIGGER|TID=name[,INTF|IID=intf-id]`
  This command enables a Substation ES trigger that is disabled. The `TRIGGER` keyword specifies the name of the trigger to be enabled. The optional keyword `INTF|IID=intf-id` specifies an ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command Entered 'ENABLE,TID='CICS-RR-REQUEST''
      SXT5838I The following recipe/trigger is enabled Intf:IIXFR,
               TID:CICS-RR-REQUEST

## RECOVER Command

The RECOVER command instructs the TIBCO Enterprise Message Service (EMS) server to redeliver all unacknowledged messages that are stored in the EMS queue. The Substation ES recipe definition contains the queue name from which the redelivered messages originate.

Undelivered messages are the result of previous, unsuccessful processing if the Substation ES service mode is Guaranteed Always (GA). The RECOVER command is the only nondisruptive method for recovering undelivered messages.

`RECOVER,RECIPE|RID=name[,INTF|IID=intf-id]`

`RECOVER,*[,INTF|IID=intf-id]`

`RECOVER,`*[,FOR=BES-Name,INTF|IID=intf-id]``

The RECIPE keyword identifies the name of the EMS queue that is recovered. The optional keyword INTF|IID=intf-id specifies an ESB interface identifier.

Note: This command instantiates the `tibems_Session` Recover API call.

For example:

RECOVER,* |
RECOVER,*,`FOR=CICS` | Recover is for all recipes with BES referencing CICS.
RECOVER,*,`XYZ` | XYZ means nothing.
RECOVER,*,`IID=ESB1` | Recover is sent only to interface ESB1.
RECOVER,`RID=ABC` |
RECOVER,`RECIPE=ABC` |
RECOVER,`RID=ABC,IID=ESB1` | Recover is sent only to interface ESB1.

## REFRESH | REFR Command

The REFRESH|REFR command instructs the Substation ES transformer to load a new copy of a service (recipe or trigger) in-flight. The old recipe or trigger is deactivated and unloaded when the new copy is loaded and activated.

If the recipe or trigger was not loaded during Substation ES initialization, you can use this command to load and activate the recipe or trigger. When the command is successfully completed, the message number `SXT5811I` is written to the log and trace files.

The REFRESH command also refreshes the current counters for all the active interfaces, whether or not there has been a change in the service details.

If the recipe is in suspended state when a REFRESH command is issued, the command loads the recipe but the state remains in suspended mode. The newly loaded recipe becomes active again only when it has been unsuspended.

The REFRESH|REFR commands are used in the following ways:

REFRESH|REFR,`RECIPE|RID=name[,INTF|IID=intf-id][,TRCLVL=value]`
  This command loads a recipe as described previously. The `RECIPE` keyword specifies the name of the recipe to be refreshed. The optional keyword `INTF|IID=intf-id` specifies that the recipe is to be refreshed with the specified ESB interface identifier. The optional keyword `TRCLVL=value` specifies that the recipe service sets the trace level in the memory to the value indicated. However, the trace level in the configuration file won't be changed.
  The command output is as follows:

      SXA2601I Console Command 'REFR,RID=SXC-DPL-C,TRCLVL=3'
      SXT5811I IId:XFREA1 Recipe SXC-DPL-C refreshed - still for
               tibss.CICS.C.Request
      SXT5680I IId:XFREA1 Recipe SXC-DPL-C reloaded
               Trace Level set to 3
      SXA2666I End-of-Command

REFRESH|`REFR,TRIGGER|TID=name[,INTF|IID=intf-id][,TRCLVL=value]`
  This command loads a trigger as described previously. The `TRIGGER` keyword specifies the name of the trigger to refresh. The optional keyword `INTF|IID=intf-id` specifies that the trigger is to be refreshed with the specified ESB interface identifier. The optional keyword `TRCLVL=value` specifies that the trigger service sets the trace level in the memory to the value indicated. However, the trace level in the configuration file won't be changed.
  The command output is as follows:

      SXA2601I Console Command 'REFR,TID=TRIGGER-TEXT,TRCLVL=2'
      SXT5487I IId:XFREA1 Trigger TRIGGER-TEXT refreshed
               Trace Level set to 2
      SXA2666I End-of-Command

REFRESH|REFR,`COUNTERS`
  This command refreshes the Substation ES counters.
REFRESH|REFR,`RECIPE|RID|TRIGGER|TID,ALL[,INTF|IID=intf-id]`
  This command refreshes all recipes or triggers currently loaded in the Substation ES; including any disabled recipes or triggers. This operation will not load any new or unloaded recipe or trigger from the configuration file. The optional keyword `INTF|IID=intf-id` specifies that the recipes or triggers are to be refreshed with the specified ESB interface identifier.
  Depending on the number of recipes or triggers to be refreshed, this command might take a long time. For example, 30 - 45 seconds.
  If a recipe or trigger is in use, then the process waits half a second for work to be cleared before trying the definition refresh again. Substation ES attempts the definition refresh 10 times before abandoning the definition and proceeding to the next definition.
REFRESH|REFR,`TPORT=tport-id[,INTF|IID=intf-id]`
  This command refreshes the ESB endpoint tport-id which is currently loaded in the Substation ES. This operation loads the ESB endpoint from the configuration file. The optional keyword `INTF|IID=intf-id` specifies that the ESB endpoint is to be refreshed with the specified ESB interface identifier.

## RELOAD Command

The RELOAD command instructs the Substation ES transformer to reload a new copy of a service (recipe or trigger) in-flight. The old recipe or trigger is deactivated and unloaded when the new copy is loaded and activated.

This command will not load and activate the recipe or trigger, if the recipe or trigger was not loaded during Substation ES initialization.

The RELOAD command also refreshes the current counters for all the active interfaces, irrespective of whether there has been a change in the service details.

If the recipe is in suspended state when a RELOAD command is issued, the command loads the recipe in suspended mode. The suspended recipe becomes active once it has been unsuspended.

The RELOAD commands are used in the following ways:

RELOAD,`RECIPE|RID=name[,INTF|IID=intf-id]`
  This command loads a recipe. The `RECIPE` keyword specifies the name of the recipe to be reloaded. The optional keyword `INTF|IID=intf-id` specifies that the recipe is refreshed with the specified ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command 'RELOAD,RID=SXI-TRAN'
      SXT5816I IId:ESBRA1 Recipe SXI-TRAN refreshed, destination
               tibss.IMS.Tran.Request
      SXT5680I IId:ESBRA1 Recipe SXI-TRAN reloaded
      SXA2666I End-of-Command

RELOAD`,TRIGGER|TID=name[,INTF|IID=intf-id]`
  This command loads a trigger as described previously. The `TRIGGER` keyword specifies the name of the trigger to reload. The optional keyword `INTF|IID=intf-id` specifies that the trigger is to be reloaded with the specified ESB interface identifier.
  The command output is as follows:

      SXA2601I Console Command 'RELOAD,TID=TRIGGER-BYTES,IID=ESBRA1'
      SXT5487I IId:ESBRA1 Trigger TRIGGER-BYTES reloaded
      SXA2666I End-of-Command

RELOAD,`RECIPE|RID|TRIGGER|TID,ALL[,INTF|IID=intf-id]`
  This command reloads all recipes or triggers currently loaded in the Substation ES; including any disabled recipes or triggers. This operation will not load any new or unloaded recipe or trigger from the configuration file. The optional keyword `INTF|IID=intf-id` specifies that the recipes or triggers are to be reloaded with the specified ESB interface identifier.
  Depending on the number of recipes or triggers to be refreshed, this command might take a long time. For example, 30 - 45 seconds.
  If a recipe or trigger is in use, then the process waits half a second for work to be cleared before trying the definition reload again. Substation ES attempts the definition refresh 10 times before abandoning the definition and proceeding to the next definition.

## SUSPEND Command

The SUSPEND command instructs the Substation ES ESB interface to stop processing for an individual recipe, or all recipes related to a particular BES.

The suspended state is different from a disabled state where a service's counter is not cleared and the service's internals remain intact. It's recommended that a SUSPEND command for a particular BES should not be explicitly issued because when suspended, Substation will not unsuspend the BES when it is connected. You must manage the BES explicitly to unsuspend it.

An individual recipe service can be enabled by using the standard ENABLE,`RID=xxx` command.

Note: If a recipe service has both BES and Alt-BES specified, the service will only be suspended when both BES and Alt-BES are down (not available).

The SUSPEND commands are used in the following ways:

SUSPEND,`*,FOR=BES-Name[,INTF|IID=intf-id]`
  This command when issued internally suspends all Substation ES recipe services for BES or Alt-BES. The `BES-Name` keyword is used to filter the recipes selected for BES or Alt-BES that is equal to `BES-Name`. The optional keyword `INTF|IID=intf-id` specifies that the recipes with the specified ESB interface identifier are suspended.
  The command output is as follows:

      SXA2601I Console Command 'SUSPEND,*,FOR=IMS'
      SXA2685I Suspending all services for BES:IMS
      SXT5838I Service is suspended, RID:SXI-TRAN
      SXT5838I Service is suspended, RID:SXI-TRAN-AND-TRG
      SXT5838I Service is suspended, RID:SXI-TRAN-BYTE

SUSPEND,`RECIPE|RID=name[,INTF|IID=intf-id]`
  This command suspends a recipe. The `RECIPE` keyword specifies the name of the recipe to suspend. The optional keyword `INTF|IID=intf-id` specifies that the recipe with the specified ESB interface identifier is suspended.
  The command output is as follows:

      SXA2601I Console Command 'SUSPENDED,RID=SXI-TRAN'
      SXA2686I Suspending Service RID:SXI-TRAN
      SXT5838I Service is suspended, RID:SXI-TRAN

Copyright © TIBCO Software Inc. All rights reserved.