Deleting unnamed snapshots in bulk from a Process Center server

You can configure IBM® Process Center to automatically delete unnamed snapshots in bulk at a scheduled time from all process applications and toolkits.

Before you begin

You must be a development environment administrator with access to the local configuration files on the server to do this task.

About this task

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 process 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 version 0.3 are deleted.
    Note: Archived snapshots are ignored when calculating the range of snapshots to be deleted. For example, if versions 0.3 and 0.4 are archived snapshots, then they are skipped, and only unnamed snapshots that were created before version 0.1 are deleted.

    As the <clean-after-number-named-snapshots> setting applies at the track level, the unnamed snapshots that meet the criterion are deleted from each individual track in the project. Conversely, if a track has fewer named snapshots than the specified value, the unnamed snapshots in that track are not 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>
	

For more information about changing configuration properties, see the topic Creating a 100Custom.xml configuration file.

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.