IBM Streams 4.2

Creating host pools

A host pool is set of resources that can be designated for a particular purpose. For example, you can specify a set of hosts that are optimized to run a specific type of analysis and assign operators that perform that analysis to the host pool.

Before you begin

To use a submission-time parameter that affects how operators are fused, you must specify a fusion scheme other than legacy. This means that you must recompile your applications with IBM® Streams Version 4.2 or later.

About this task

When you submit a job, you might want to create new host pools based on the hosts that are available in the instance where you plan to deploy the application. For example, the host pools that are defined in the application bundle file might not be meaningful in the instance where you are deploying the application, or you might want to create new host pools based on how you plan to co-locate and ex-locate the operators when you submit the job.

You can create host pools from the IBM Streams Console, IBM Streams Studio, or the streamtool submitjob command. However, if you use the streamtool submitjob command, you must use a job configuration overlay file to specify these settings. A job configuration overlay file is optional if you use IBM Streams Console or IBM Streams Studio.

To create a host pool, you must specify the following information:
name
Specify the name of the host pool.
operatorsInPool
Specify a list of the operators that you want to include in the host pool.
Restriction: When you specify the list of operators, keep the following restrictions in mind:
  • An operator can be in only one host pool
  • If you specified a declared host for an operator when you specified the properties of the operator, you cannot include the operator in a host pool.
To specify which operators you want to include in the pool, you must specify:
nameSpec
You can use the nameSpec parameter to specify the name of a single operator or you can specify a group of operators:
  • To specify a single operator to include, specify the name of an existing operator instance in the application after UDP transformations.
    Restriction: You can specify only one nameSpec entry within an OperatorsInPool element. If you want to specify more than one operator, you can specify multiple OperatorsInPool elements.
  • To specify a group of operators to include, use an asterisk (*) as a wildcard character. You can specify 0 or more wildcard characters. For example:
    • Enter myParallelRegion.myOperator[*] to include all of the channels of the parallel region
    • Enter MyComposite.firstComposite.* to include all of the operators in the composite region
Tip: Wildcard characters can be especially helpful when operators with related concerns are named following a particular pattern. For example, if the application has several FileSink operators that are all used for debugging, including "Debug" in their name allows you to easy control all of their behavior at the same time.
inPoolIndex
If you specify a size for the host pool, you can optionally specify the index for the operators (that are specified by the corresponding nameSpec) within the host pool. The index must be less than the pool size. For example, if you specify a pool size of 5, you can specify that this operator uses the fourth host in the host pool.
membershipMode
  • Specify shared if the hosts in the host pool can be in more than one pool. This is the default value.
  • Specify exclusive if the hosts in the host pool cannot be in any other pools. This restriction applies to this job and to any other job that you submit.
    Restriction: If you specify exclusive, you cannot use the declaredHosts option.
size
Specify the maximum number of hosts that can be included in the pool. If you specify a value, you must specify an integer greater than 0.
Restriction: If you specify a list of hosts (rather than specifying host tags), this setting is ignored.
tags
If you want to use tags to specify which hosts to include in the host pool, specify a list of tags.
Hosts that have one or more of the tags that you specify are considered for membership in this pool. Some hosts that meet the criteria might be excluded if:
  • You specify a pool size that is smaller than the number of matching hosts
  • A matching host is a member of an exclusive host pool
Restriction: If you specify tags, you cannot specify declaredHosts.
declaredHosts
If you want to include specific hosts in the host pool, specify a list of hosts.
Restriction: If you specify declaredHosts, you cannot specify tags. Additionally, this option is not valid if you set the membershipMode to exclusive.