You can define a service that dynamically returns a set
of users and managers at run time.
Before you begin
To perform this task, you must be in the IBM® Process
Designer desktop
editor.
About this task
A team retrieval service can use custom defined input
parameters to resolve a set of team members and team managers.
Procedure
- Open the Process Designer desktop editor.
- If you want to create a team that is dynamically resolved,
complete the following actions in the Designer view.
- In the library, click the plus sign to next to the Teams category.
- In the New Team window, enter
a name for the team and click Finish.
- In the team editor, choose to specify team members by using
a service.
- Click New.
- Enter a suitable name for the service, for example, Claims
Team Retrieval Service.
- Select the Variables tab. The mandatory input and output variables are already present
and are locked. If the new team retrieval service requires information
from the activity, add input parameters and specify the variable details.
Important: If you want to use this dynamic team as the managers
of another team, you can use only additional input parameters that
have default values that are defined for them.
- Select the Diagram tab and provide
the implementation of the service. Based on the input parameters,
the service must return a Team object that contains
a list of team members. It can also optionally include the name of
a team of managers, and optionally the name of the team (this parameter
is ignored).
- If you want the results of the service to be cached for each
combination of input parameter values, select the Overview tab,
then in the Service Result Cache section, select Enable
caching of service results to display the cache configuration
fields. By default caching is disabled.
- When caching is disabled, the Cache results for section
is not displayed.
- When caching is enabled, the Cache results for section
is displayed. By default, when caching is enabled, the results for
each combination of input parameter values are kept in the cache for
12 hours. To change the caching period, use the Days, Hours, Minutes,
and Seconds fields to select the duration that
you want.
Important: Depending on the size of the results,
you might need to tune the size of the service results cache to avoid
memory problems. By default, the cache stores up to 4096 results.
You can change the size of the cache by setting a different value
for <service-result-cache-size> in the 100Custom.xml file,
inside the <server merge="mergeChildren"> section.
Restriction: The service results cache setting works only for top-level
services, which are services that are directly started by a BPD. When
a service is called by another service, the service results cache
setting for the nested service is ignored and the results for the
nested service are not cached.
- To use an existing team retrieval service, complete the
following steps.
- Click Select. A selection dialog
is displayed that lists all existing services that match the team
retrieval service template.
- Select the team retrieval service that you want to use.
- If the team retrieval service that you selected requires
extra parameters, then the Team Retrieval Service Input
Mapping section is displayed. For each required
parameter, enter the corresponding environment variable name or literal,
for example tw.env.businessPriority.
Results
The team's members are determined dynamically by the appropriate
team retrieval service. If you defined a new team retrieval service,
it is available to select when you assign activities to teams, as
described in
Assigning teams to BPD activities.