streamtool updateoperators

The streamtool updateoperators command lets you adjust a job configuration while the job is running in order to improve the job performance. In addition, you can view the current configuration of a job.

Usage

updateoperators

Read syntax diagramSkip visual syntax diagramjob-id--jobnamejob-name-g--jobConfigfile-name-a--addCpuSpecrequest,limit-r--reduceCpuSpecrequest,limit--force--parallelRegionWidthparallel-region-name= width-q--out_jobConfigfile-name-U--Useruser-h--help--tracelevel-v--verboselevel

Authority

You must have add and delete authority for the appropriate jobgroup_<name> instance object. By default, the InstanceAdministrator role has this authority. The user who submits the job also has this authority. For more information about access control lists, see the streamtool getacl and streamtool lsjobpermission commands.

Description

Use this operation to update a subgraph of a running job. You can increase or decrease the width of a parallel region. If you increase the width, you can optionally increase the number of CPU cores that are assigned to the job.

You can also use this command with just the job ID or job name to view the current configuration of a job, for example, to see the job's fusion scheme or the current width of its parallel regions.

All affected operators and their associated processing elements (PEs) must be stopped before the update can be performed. You can use the --force option to automatically stop the PEs or you can stop the PEs manually before you submit this operation. The PEs are restarted after the update is complete.
Restrictions:
  • You cannot modify the parallel region width of a running job when the original job was submitted with the parallel region fusion (fusionType) parameter set to channelExlocation (prevent fusion across channels). You must resubmit the job with the fusionType parameter set to noChannelInfluence (default) or to channelIsolation.
  • Checkpointing is not supported in the parallel region, including collateral operators.
  • Consistent regions are not supported in the parallel region, including collateral operators.
Caveats:
  • The streamtool updateoperators command stops and restarts the operators in the parallel region and their associated PEs. This action can result in loss of tuples and operator state information.
  • The operation might take some time, depending on the number of operators that are affected.
  • The operators that are in each PE can change. The PE ID might not be consistent for the lifetime of an operator. You can use the streamtool lspes --long command to see the PE IDs.
  • Confirm with the application developer that changing the parallel region width will not interfere with any settings in the running application. For example, if the region includes sink operators that are matched with an externally partitioned system.

The operation fails without making any changes if the PEs in the parallel region cannot be placed because of incompatible placement constraints.

Options and arguments

-a, --addCpuSpec <request,limit>
The requested and maximum number of CPU core resources to increase the current CPU specification for the job. The specification applies to operators within the parallel region that is specified by the --parallelRegionWidth option.
--force
Specifies whether to automatically stop the PEs that need to be stopped. If you do not specify this option, you must manually stop the PEs before you submit this operation.
-g, --jobConfig <file-name>
Specifies the name of an external file that defines a job configuration overlay. You can use a job configuration overlay to set the job configuration when the job is submitted or to change the configuration of a running job. For information about how job configuration overlays work, see Job configuration overlays. For the list of the job configuration parameters that you can use with this command, see the Job configuration overlays reference.
-h, --help
Specifies to show the command syntax.
<job-id>
Specifies a job identifier.
--jobname <job-name>
Specifies the job name for the submitted job.
--parallelRegionWidth <parallel-region-name>=<width>
Specifies a parallel region name and its width. The parallel region name is the name of the logical operator that the @parallel annotation is applied to.
-q, --out_jobConfig <file-name>
Specifies the name of the output file in which the command writes the operator configuration information. For more information, see Job configuration overlays reference.
-r, --removeCpuSpec <request,limit>
The requested and maximum number of CPU core resources to reduce the current CPU specification for the job. The specification applies to operators within the parallel region that is specified by the --parallelRegionWidth option.
--trace <level>
Specifies the trace setting. The following valid levels are listed in order of increasing verbosity, which is to say that the first level in the list generates the least amount of information:
  • off
  • error
  • warn
  • info
  • debug
  • trace
The default value is off.
-U, --User <user>
Specifies an IBM® Streams user ID that has authority to run the command.
-v,--verbose <level>
Specifies to provide more detailed command output. The verbosity level can be 0-3, where 0 disables detailed reporting and each increment provides more detailed output.

Examples

The following command writes information about job 0, for example, the current parallel region widths, to the indicated file.
[streamsops@myinstance-ops-0 ~]$ streamtool updateoperators 0
CDISC0217I The update operators operation was started on the myinstance instance..
CDISC0216I The operator configuration results were written to the following file: my_job::UDP1_0_config.json.
The following information is contained in the output file.
{
  "results": {
    "parallelRegionsInfo": [
      {
        "name": "myParallelRegion1",
        "width": 3
      }
    ],
    "deploymentConfig": {
      "fusionScheme": "automatic",
      "threadingModel": "notSpecified"
    }
  }
}
The following command sets the width of parallel region myParallelRegion1 to 5 for job 0.
[streamsops@myinstance-ops-0 ~]$ streamtool updateoperators 0 --force --parallelRegionWidth myParallelRegion1=5
The following command sets the width of parallel region myParallelRegion1 to 8. The command also adds two CPU core resources to the requested resources and four CPU core resources to the maximum resources for operators in that parallel region.
[streamsops@myinstance-ops-0 ~]$ streamtool updateoperators 0 --force --parallelRegionWidth myParallelRegion1=8 --addCpuSpec 2,4