BPMDeleteDurableMessages command

The BPMDeleteDurableMessages command deletes old durable subscription messages from the LSW_DUR_MSG_RECEIVED database table.

Durable subscription messages exist and persist in the LSW_DUR_MSG_RECEIVED database table if durable subscriptions are enabled for message events or content events of the following types:
  • intermediate
  • boundary
  • start events of event subprocesses
The BPMDeleteDurableMessages command deletes durable subscription messages based on their age. You can use this capability to trim the size of the LSW_DUR_MSG_RECEIVED database table periodically.

The BPMDeleteDurableMessages command is run using the AdminTask object of the wsadmin scripting client.

Prerequisites

Note: In an environment with multiple security domains configured, use the PALService MBean instead of this wsadmin command. See The Process Application LifeCycle (PAL) MBean.
The following conditions must be met:
  • Run the command in the connected mode, that is, do not use the wsadmin -conntype none option.
  • To run this command, you must be a user in the DeAdmin role. In a network deployment environment, you must run this command on the node containing the application cluster member that handles Process Server applications. Do not run this command from the deployment manager profile.
  • You cannot use this command to delete messages for BPEL processes.
  • You can run the command from any cluster member in a network deployment environment. However, you must first establish the wsadmin session to the SOAP port of the cluster member from where you are running the command.

Location

Start the wsadmin scripting client from the install_root/profiles/deployment_manager_profile/bin directory.

Syntax

BPMDeleteDurableMessages 
-olderThan age_in_days
[-maximumDuration number_of_minutes]
[-transactionSlice number_of_messages]

Parameters

-olderThan age_in_days
Specifies an age in days. Durable subscription messages that are older than the specified age are deleted when the command is run. This parameter is required.
Tip: A day is interpreted as a period of 24 hours rather than as a calendar day. For example, if you specify a value of 3 for the -olderThan parameter, it is interpreted as 72 hours rather than as 3 calendar days. As a result, all durable subscription messages that are older than 72 hours will be deleted when you run the command. However, durable subscription messages that were created 3 calendar days ago, but less than 72 hours ago, will not be deleted
-maximumDuration number_of_minutes
Specifies the maximum duration of the deletion operation in minutes. The default value is 0 (which is equivalent to an unlimited number of minutes). When the maximum duration is exceeded, the command is aborted after the current transaction has committed. This parameter is optional.
-transactionSlice number_of_messages
Specifies the number of durable subscription message instances that are deleted with each transaction. The default value is 1000. This parameter is optional.

Example

wsadmin -conntype SOAP -port 8880 -host ProcessServer01.mycompany.com -user admin -password admin -lang jython 

wsadmin>AdminTask.BPMDeleteDurableMessages( ['-olderThan', '30', '-maximumDuration', '60', '-transactionSlice', '100' ] )