IBM BPM, V8.0.1, All platforms > Administer the IT infrastructure > Administer Business Process Choreographer > Use scripts to administer Business Process Choreographer
Refreshing people query results, using administrative scripts
Use an administrative script to refresh people queries, because the results of a people query are static.
The following conditions must be met:
- Run the script in connected mode, that is, the application server must be running. Do not use the wsadmin -conntype none option.
- If Business Process Choreographer is configured on a cluster, then at least one cluster member must be running.
- If WebSphere administrative security is enabled, and your user ID does not have operator authority, include the wsadmin -user and -password options to specify a user ID that has operator authority.
If you are not working with the default profile, use the wsadmin -profileName profile option to specify the profile.
Business Process Choreographer caches the results of people queries, which have been evaluated against a people directory, such as a Lightweight Directory Access Protocol (LDAP) server, in the runtime database.
If the people directory changes, you can force the people assignments to be evaluated again.
Procedure
- Change to the Business Process Choreographer subdirectory where the administrative script is located.
cd INSTALL_ROOT/ProcessChoreographer/admin
cd INSTALL_ROOT/ProcessChoreographer/admin
cd INSTALL_ROOT\ProcessChoreographer\admin
- Force the people assignment to be evaluated again.
INSTALL_ROOT/bin/wsadmin.sh -f refreshStaffQuery.py [ ([-node nodeName] -server serverName) | (-cluster clusterName) ] [-processTemplate templateName | (-taskTemplate templateName [-nameSpace nameSpace]) | -userlist username{, username}...]
INSTALL_ROOT/bin/wsadmin.sh -f refreshStaffQuery.py [ ([-node nodeName] -server serverName) | (-cluster clusterName) ] [-processTemplate templateName | (-taskTemplate templateName [-nameSpace nameSpace]) | -userlist username{, username}...]
INSTALL_ROOT\bin\wsadmin -f refreshStaffQuery.py [ ([-node nodeName] -server serverName) | (-cluster clusterName) ] [-processTemplate templateName | (-taskTemplate templateName [-nameSpace nameSpace]) | -userlist username{, username}...]Where:
- -node nodeName
- The name of the node where Business Process Choreographer is configured. This is optional when specifying the server name. The default is the local node.
- -server serverName
- The name of the server where Business Process Choreographer is configured. This is required if a cluster is not specified.
- -cluster clusterName
- The name of the cluster where Business Process Choreographer is configured. This is required if Business Process Choreographer is configured on a cluster.
- -processTemplate templateName
- The name of the process template. People assignments that belong to this process template are refreshed.
- -taskTemplate templateName
- The name of the task template. People assignments that belong to this task template are refreshed. The refresh is not performed for the default user, but for the staff queries that model task roles.
If the refresh fails, then the queries for the fallback user are not refreshed, for example, for the process administrators.
- -nameSpace nameSpace
- The target namespace of the task template.
- -userlist userName
- A comma-separated list of user names. People assignments that contain the specified names are refreshed. The user list can be surrounded by quotation marks. If the quotation marks are omitted the user list must not contain blanks between the user names.
If you do not specify any templateName nor userlist, all people queries that are stored in the database are refreshed.
You might want to avoid this for performance reasons.
- If the script triggers long-running work on the server, the script might fail if the connection timeout is not long enough to complete the action. Check the SystemOut.log file on the server to see whether you need to restart the script. If the timeout happens often, consider increasing the value of the timeout property for the connector you are using, or adjusting the script parameters to reduce the amount of work done on the server.
Use scripts to administer Business Process Choreographer
Related tasks:
Refreshing people query results, using the administrative console
Refreshing people query results, using the refresh daemon