Deleting unnamed snapshots from a Process Center server, automated method

You can configure IBM® Process Center to automatically delete unnamed snapshots that you no longer need to keep on the server.

Before you begin

Important: Before you begin this task, you must install interim fixes. See the Issues with BPMDeleteSnapshot and BPMSnapshotCleanup commands in IBM Business Process Manager (BPM) flash technote.

You must be a repository administrator or development environment administrator to do this task.

About this task

A named snapshot is a snapshot that has a version number or other identifier. Unnamed snapshots exist between the named snapshots. Every time that a Process Designer user saves work, an unnamed snapshot is created on the Process Center server. Hundreds of unnamed snapshots quickly accumulate. If you have many projects under development in the Process Center, the Process Center database is likely to grow rapidly. Reduce database bloat by removing the unnamed snapshots. You might also want to delete unnamed snapshots if your Process Center server performance is slowly degrading.

Keep the following points in mind while you plan how to use this feature:
  • Automatic deletion never removes named snapshots.
  • Because automatic deletion randomly chooses which process applications and toolkits to work on, specify a duration that is long enough to process all the active projects in your Process Center.
  • Automatic deletion removes unnamed snapshots in chunks of 100 to limit database contention. If the duration time expires before all the unnamed snapshots are removed, automatic deletion might not remove all the unnamed snapshots between two named snapshots.
  • Automatic deletion runs only when the server is up. If the server is down when the configured start time occurs, automatic deletion will not run until the next time the deletion feature is configured to start.
  • Before deleting unnamed snapshots, go to the Process Designer Inspector and remove all BPD instances that are related to each unnamed snapshot that you want to delete.
  • Delete unnamed snapshots when there are no operations on the Process Center and no connections between the Process Designer and the Process Center.

The feature to automatically delete unnamed snapshots is controlled by a set of configuration options in the <server> section of the 100Custom.xml file. The section begins with the heading <unnamed-snapshots-cleanup-config>.

Procedure

  1. To turn on the automated deletion feature, set <enabled> to true. The default setting is false.
  2. To set the time of day when you want the automated snapshot deletion to run, provide a value for <cleanup-start-time>. The time that is used is the local computer time. The default time is midnight: 23:59:59. The automatic snapshot deletion process makes intensive use of the database; therefore, run the process when other demands on the system are low. Running it during times of heavy use slows the response time for people using the system.
  3. Set <cleanup-duration-minutes> to the number of minutes that you want the process to run. The default duration is 5 minutes.
  4. To define which snapshots you want to delete, set <clean-after-number-named-snapshots>. Deleting snapshots removes some of the change history for your project; therefore, you probably want to keep the most recent snapshots. The default setting is 4, which means that only unnamed snapshots that are older than the four most recent named snapshots are deleted. With that setting, if the Process Center server has versions 0.1 to 0.6 on it, only unnamed snapshots that were created before the named snapshot for version 0.3 would be deleted.

Example

The relevant section in the 100Custom.xml file looks like this example, which uses default settings:

<unnamed-snapshots-cleanup-config>
   <enabled>true</enabled>
   <cleanup-start-time>23:59:59</cleanup-start-time>
   <cleanup-duration-minutes>5</cleanup-duration-minutes>
   <clean-after-number-named-snapshots>4</clean-after-number-named-snapshots>
</unnamed-snapshots-cleanup-config>
	

What to do next

The easy way to manage the accumulation of unnamed snapshots on your Process Center server is to enable automated deletion. However, you can also delete specific unnamed snapshots or archived snapshots. See Deleting unnamed and archived snapshots, manual for details.

To see the results from the automated deletion process, check the AppTarget cluster server log file.