Tuesday, December 16, 2014

IBM BPM Instrumentation Page - A very good way to Monitor IBM BPM


Instrumentation Explained for IBM BPM.

What is Instrumentation?
How to use Instrumentation?
What all we can monitory using Instrumentation?

If you have above or similar kind of question, you should visit the post written by  Sergei Malynovskyi in BP3 Portal. It is really well written post.

Best thing to take from the post is how to see extended data in instumentation monitor page. 

If you dont know it already, it will open whole new world of monitoring you can do for IBM BPM. You can also visit below Tech Note for more details.





Sunday, November 2, 2014

Second Page of custom saved search result reset back to previous saved search's column and filter - IBM BPM Portal

Problem
Whenever we try to execute a custom search or quick search first page of result comes as expected but as soon as we click on second or any other page from pagination menu custom search gets back to default or last clicked saved search.

Solution 
We raised this issue with IBM and they came back with an IFix to solve this issue.
apparently this issue is related to cookie in local browser. whenever we click on second or any other page, it get redirected to the saved search that is related in cookie and search filter, sorting and column get details from saved search in cookie. 
To solve this problem, JR49440 Needs to be installed.

Go to, IBM Fix Central and find JR49440 related to your current IBM BPM version.
More details can find in below tech-note


Monday, June 9, 2014

EXECUTION_STATUS column in LSW_BPD_INSTNCE table

You need to query the database to get the status of your business process definition (BPD) instances. What is the meaning of the EXECUTION_STATUS field in the LSW_BPD_INSTANCE table?

Flag Meaning
1 The BPD instance is active.
2 The BPD instance has completed.
3 The BPD instance has failed. Look at the ERROR and ERROR_STACK_TRACE for further details.
4 The BPD instance has terminated.
5 The BPD instance did not start because its message event condition returned false.
6 The BPD instance is suspended,

Thursday, May 8, 2014

Pythagoras Cup - Greedy Cup


Was just surfing the youtube yesterday and found below. Really interesting.
Hope you like it.




Friday, April 4, 2014

UCA disappearing from Event Monitor or Corrupted UCA problem in IBM BPM - Solved

Problem Description - 
==============
Facing issues with Event Monitor related to UCA scheduling , its behaving weird the entries are randomly disappearing from the scheduler .

Even after re-enabling(checking unchecking from the application side) , the UCA appear in event Monitor for short time and disappear after one run or after some time.

Reason for Problem -
=============
When a time-based UCA is scheduled, an event manager task in the
LSW_EM_TASK table and two keywords in the LSW_EM_TASK_KEYWORDS 
table are created. These keywords are 'UCA4.<uca-id>' and 
'scheduledExec'. On rare occasions, you might see event manager 
tasks for time-based UCAs that have only the 'scheduledExec' 
keyword. When a UCA is rescheduled, the keywords are used to 
delete the previous event manager task.  However, having only 
the 'scheduledExec' keyword for a particular UCA could cause all 
other time-based UCAs to be deleted during the rescheduling 
process.
In our case we believed reason for this problem was due to our DB file system was running at 100% at couple of times.

Solution -
======
The proposed solution is to manually delete the corrupted task from the database. This must be done carefully in order to not corrupt the whole database. The following queries should be executed at times     
where they do not interfere with the scheduling time of the UCA, i.e. not at full hours, or 5,15,25,35,45 or 55 minutes after full hours or you UCA is about to get executed.

There are can be two type of problem as one of the keyword for perticular UCA is not present. I will explain both scenarios.

Scenario 1 -
------------
1.) Retrieve TASK_IDs for scheduled UCAs that have only the 'scheduledExec' keyword, but not the uca id keyword:

select task_id from lsw_em_task_keywords where keyword = 'scheduledExec' and task_id not in ( select task_id  from lsw_em_task_keywords where keyword like 'uca4%')


2.) Display description and ID of ucas returned by query2:  

select description,task_arguments_str from lsw_em_task where task_id in(select task_id from lsw_em_task_keywords where keyword = 'scheduledExec' and task_id not in ( select task_id  from lsw_em_task_keywords where keyword like 'uca4%'))

3.) If the result of query 2 shows only tasks with description "Execute UCA <UCA_Name> <Schedule>, on set schedule", then you can delete the corrupt UCA and keyword with the following queries:  

3.1) Delete corrupted lsw_em_task: 

delete from lsw_em_task where task_id in (select task_id from lsw_em_task_keywords where keyword = 'scheduledExec' and task_id not in (select task_id  from lsw_em_task_keywords where keyword like 'uca4%'))

3.2) Delete corrupted lsw_em_task_keyword:

delete from lsw_em_task_keywords where task_id in (select task_id from lsw_em_task_keywords where keyword = 'scheduledExec' and task_id not in (select task_id  from lsw_em_task_keywords where keyword like 'uca4%'))

Scenario 2 -
------------
1.) Retrieve TASK_IDs for scheduled UCAs that have only the  uca id keyword, but not the 'scheduledExec' keyword:

select task_id from lsw_em_task_keywords where keyword = 'uca4%' and task_id not in ( select task_id  from lsw_em_task_keywords where keyword like 'scheduledExec')


2.) Display description and ID of ucas returned by query2:

select description,task_arguments_str from lsw_em_task where task_id in (select task_id from lsw_em_task_keywords where keyword = 'uca4%' and task_id not in ( select task_id  from lsw_em_task_keywords where keyword like 'scheduledExec'))

3.) If the result of query 2 shows only tasks with description " Execute UCA <UCA Name>, on set schedule",then you can delete the corrupt UCA and keyword with the following queries:  

3.1)  Delete corrupted lsw_em_task:

delete from lsw_em_task where task_id in (select task_id from lsw_em_task_keywords where keyword = 'uca4%' and task_id not in (select task_id  from lsw_em_task_keywords where keyword like 'scheduledExec'))                                                       
                                                                        
3.2) Delete corrupted lsw_em_task_keyword:

delete from lsw_em_task_keywords where task_id in (select task_id from lsw_em_task_keywords where keyword = 'uca4%' and task_id not in (select task_id  from lsw_em_task_keywords where keyword like 'scheduledExec'))       

You could also only delete the corrupt task keyword with Query4. APAR JR47574 will then take care, that the associated UCA task is not executed and not rescheduled

Saturday, March 15, 2014

Changing Configuration in IBM BPM Configuration file usitn 100Custom.xml

In IBM BPM most of the configuration details are stored in 99Custom.xml file. There are lots of instances when you need to change this default settings/configuration to the customized one.
When ever you modify a server configuration,always make the changes to the 100Custom.xml file,not to the original configuration file.In this way , all customization's are captured in a single file and are readily available if you upgrade to a new version of IBM BPM. This is the recomanded process as it is very easy to rollback from here without forgetting what was the “out-of-box/Defualt“ value for the given parameter/tag.
For example, the 100Custom.xml and 99Local .xml files are stored in the profile root for the server, where the value is either process-center or process-server, depending on which server you are configuring.  

The configuration files in the ../config/ directories are loaded in numerical order. For example, the standard files are loaded in this order: 00Static.xml, 50AppServer.xml, 60Database.xml, 80EventManager.xml, 98Database.xml, 99Local.xml, 100Custom.xml. By default, the first time the element that is loaded, it will stick in the configuration. For example,  then the one in 99Local.xmlfile loads first, unless the merge attribute is set to replace.
According to explanation on above paragraph, you can create any file of your choice having customized tag which replaces the default configuration.

Using the 100Custom.xml file to add new configuration values or replace existing values
The 100Custom.xml file is designed to hold the customization and changes that you want to make to any of the configuration files. The idea is that if you do a fresh installation of a new version, you can simply drop in your existing 100Custom.xml file and all the changes that you have made are picked up and used instead of the default values that you want to put in the 100Custom.xml file.

For example, consider adding any additional columns or views for your task manager to the 
100Custom.xml file. Any tuning options, such as for the event manager in the 80EventManager.xml file, are appropriate to put in the 100Custom.xml file. Any changes to default values, such as your system lane user, should be made in the 100Custom.xml file.

Alternatively, if you are changing your database URLs (database name, database machine name, and so on) then consider making those changes directly to the 
98Database.xml file. This approach is because these values are written down correctly when you install a new version of the product. 

One note on the 
100Custom.xml file changes: When you move to a new version of the product, you always want to review the changes in the 100Custom.xml file to make sure that they are still appropriate in the new version. For example, some of the default settings or database queries that you use in customizing the Process Portal might change between releases. Other settings might no longer apply.

The merge attribute
When you load or replace values using the 100Custom.xml file, you need to be careful which merge setting that you use for each element. The "merge" attribute supports the following:
       "append" - This setting appends the new tag.
       "mergeChildren" - This setting merges the new tag with the first of the existing tags, which is the default behavior. In other words the "mergeChildren" setting merges a child element with the parent element. However, the "mergeChildren" setting does not merge a child tag if it does not have any attributes and that child tag only has text.
       "replace" - This setting replaces all old tags with this new tag.

You can see usage examples for the "append" and "replace" settings in the 
50AppServer.xml and 60DataBase.xml files, which overrides things in 00static.xml file depending on the database or application server.

For example, from the sample 
100Custom.xml file, you might want to change the <environment-name> value. In the 99Local.xml file you have something like the following code:
<properties>
...
 <common merge="mergeChildren">
   ...
 <environment-name>Environment_from_99Local</environment-name>
   ...
 </common>
   ...
 </properties>


To change the environment name in the 
100Custom.xml file, you might use the following code:

<properties>
<common merge="mergeChildren">
<environment-name merge="replace">Environment_from_100Custom
</environment-name>
</common>
</properties>
Making changes to configuration files for a network deployment cluster
For network deployment environments, XML configuration files on the cluster level are templates for XML configuration files that are created when new cluster members are added. If you make changes to the file at the cluster member level (PROFILE_ROOT\config\cells\cell_name\nodes\custom_node_name\servers\cluster_member_name\server_type\config\100Custom.xml), make the changes at the cluster level as well (PROFILE_ROOT\config\cells\cell_name\clusters\cluster_name\server_type\config\100Custom.xml). Making the changes to the templates at the cluster level ensures that the changes are also created on any new cluster member, if one is added in the future.
At run time, only the settings from cluster member files are read. If you make changes after deployment, you need to make them in the cluster member version of the file for each server to have the changes take effect at run time.
Always make changes to any of these XML configuration files on the deployment manager server using the following steps:
1.    Make changes to cluster members, when means that you need to change the XML file for each node. See the path name that is listed earlier in this section, but work in the deployment manager file system.
2.    Make changes to the cluster level to ensure that each new cluster is created with your customized settings.
3.    Select Full Resynchronize to replicate the settings from the deployment manager server to the individual nodes. If you edit these configuration files on an individual node, the changes might be lost in the next update.

Backing up configuration files
It is always a good idea to make a backup copy of the files that you are changing. However, these configuration files are one area where you need to use some caution when backing them up. Specifically, always change the extension from .xml when backing up these files. The following information explains why you want to change the file extension:

All of the files in the 
.../config directory ending in .xml are loaded by the product on startup. These files are loaded in an alphanumeric order; letters are loaded first and then numbers are loaded in numerical order. For example, if you have the following files in the ../config directory they are loaded in the order shown below:
.../config/system/Copy of 99Local.xml
.../config/system/00Static.xml
.../config/system/50AppServer.xml
.../config/system/60Database.xml
.../config/system/80EventManager.xml
.../config/system/98Database.xml
.../config/system/99Local.xml
.../config/100Custom.xml.

If you want to get more details and explanation about this topic and also about other configuration file, specially TeamWorksConfiguration.running.xml (which is merged file from all xml configuration file created when we start the server), you can go to below links which provides more details.

Wednesday, February 19, 2014

Execute a Task in Debug Mode while PD is not available

Get the task ID.
Replace the task id and server host-name in the URL below. 
https://<HOSTNAME>/teamworks/process.lsw?zWorkflowState=1&zTaskId=2078.<TASK ID>&zDbg=1

Monday, January 6, 2014

Different Type of groups in IBM BPM

In IBM BPM, All user groups are stored in LSW_USR_GRP_XREF table. there are different types of group in IBM BPM and they are differentiated by a column 'GROUP_TYPE' in 'LSW_USR_GRP_XREF' table


There are 3 type of user groups in IBM BPM.

  1. Groups that exist and managed in external directory services like LDAP. Type 0 Groups
  2. Groups that are created in the environment through Admin Console. Type 3 groups
  3. Groups that are dynamically created by virtue of task allocation. type 1 and 2 Groups


Groups that exist and managed in external directory services like LDAP

Such groups are created and managed in external directory services like LDAP. Such groups are imported into the BPM database when an user logs in for the first time. Such groups have a GROUP_TYPE as "0" in the table LSW_USR_GRP_XREF. Such groups cannot be edited or deleted through the default Process Admin Console. They needs to be changed from external directory like LDAP.

Groups that are created in the environment through Admin Console.

These groups are created and managed through the Process Admin Console. Since these groups are not represented in the centralized directory services like LDAP, these are purposed to be used inside BPM applications only. These are analogous to TeamWorks logical roles in TeamWorks 6.2. These groups have GROUP_TYPE as "3" in the table LSW_USR_GRP_XREF.

Groups that are dynamically created by virtue of task allocation.

Groups are dynamically created when a new task is routed to a lane participant (Participant Group) or assigned to a list of users (Ad-hoc group). Dynamic groups corresponding to TeamWorks logical roles are also created during import from a 6.2 environment. These groups are not visible on the Process Admin console, hence cannot be managed. Dynamic groups that are created from Participant Groups or Logical Roles have GROUP_TYPE as "1" in the table LSW_USR_GRP_XREF, where as the dynamic groups crated from list of users have GROUP_TYPE as "2" in the table LSW_USR_GRP_XREF.