BPMSetEnvironmentVariable command

 Traditional: 
Use the BPMSetEnvironmentVariable command to set the value of an environment variable for a process app or toolkit.

Important: Don't use the BPMSetEnvironmentVariable command to update the environment variable of a toolkit if the environment variable name is not unique in the process app and all its dependent toolkits. Instead, use the Process Admin Console to update the runtime environment variable value of a toolkit.

The BPMSetEnvironmentVariable command is run using the AdminTask object of the wsadmin scripting client.

Prerequisites

The following conditions must be met:
  • Run the command in the connected mode; that is, do not use the wsadmin -conntype none option.
  • In a network deployment environment, an application cluster member runs the Workflow Server and Workflow Center applications. Therefore, you must run this command on the node that contains that application cluster member. Do not run the command from the deployment manager profile.

Location

Start the wsadmin scripting client from the install_root/bin directory.

Syntax

BPMSetEnvironmentVariable
-containerAcronym process_application_acronym
-containerSnapshotAcronym process_application_snapshot_acronym
[-containerTrackAcronym track_acronym]
-environmentVariableName Name
-environmentVariableValue Value

Parameters

-containerAcronym String
A required parameter that identifies the process application acronym. For example, the BillingDispute process application might have an acronym of BILLDISP.
-containerSnapshotAcronym String
A required parameter that identifies the process application snapshot acronym.
-containerTrackAcronym String
On a Workflow Center server, an optional parameter that identifies the acronym of the track associated with the process application.
-environmentVariableName String
The name of the environment variable that you want to set.
Restriction:
  • You can't use the BPMSetEnvironmentVariable wsadmin command to update environment variable of a toolkit if the environment variable name is not unique in a process app and its dependent toolkits. Instead, use update the runtime environment variable value of a toolkit in the Process Admin Console.
  • Ensure the environment variable name is a valid JavaScript identifier; it must begin with a letter or the _ character and can contain only letters, digits, or the _ character. The following examples are all valid names: ecmsystem_port, ecmSystem_port, and ecm_system_port.
-environmentVariableValue String
The value for the environment variable.
Tip: If you do not know the acronym for a required parameter, use the BPMShowProcessApplication command to list the details of a process application, including acronyms.

Example

The following example illustrates how to set the mediationServiceURL environment variable to a snapshot of the BillingDispute process application. The snapshot is part of the Main track. In the example, the user establishes a SOAP connection to the Workflow Center server.

Important: In a network deployment environment, use the port configured for the application cluster member that runs the Workflow Server or Workflow Center applications. To determine the correct port number, see the WebSphere® administrative console Ports collection page (click Servers > Server Types > WebSphere application servers > server_name > Communications > Ports and find the value for SOAP_CONNECTOR_ADDRESS).
wsadmin -conntype SOAP -port 8880 -host ProcessCenterServer01.mycompany.com -user admin -password admin -lang jython

wsadmin>AdminTask.BPMSetEnvironmentVariable('[-containerAcronym BILLDISP -containerSnapshotAcronym SS2.0.1 -containerTrackAcronym Main 
-environmentVariableName mediationServiceURL -environmentVariableValue https://mycompany/prodServices/mediation]')