WebLogic Integration


com.bea.wlpi.client.util
Class InstanceDeleter

java.lang.Object
  |
  +--com.bea.wlpi.client.util.InstanceDeleter

public class InstanceDeleter
extends java.lang.Object

Delete large numbers of instances in small groups to avoid EJB transaction timeouts. Suitable for wrapping in a shell script and ruinning as a cron job.

Author:
Copyright © 2000, 2001 BEA Systems, Inc. All Rights Reserved.

Constructor Summary
InstanceDeleter()
           
 
Method Summary
static void main(java.lang.String[] args)
          Delete workflow instances from a running WLI BPM system.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InstanceDeleter

public InstanceDeleter()
Method Detail

main

public static void main(java.lang.String[] args)
Delete workflow instances from a running WLI BPM system. See the EJBHelper documentation for the content and name of the optional properties file. The properties file is a good way to pass connection info (like the password) to the application so that ps doesn't display it.

Arguments (bold are mandatory):

Parameter
Meaning
-u userid WLS userid to connect to the system. If not specified it will be obtained from the properties file, if available.
-p password the WLS user's password. If not specified it will be obtained from the properties file, if available.
-org orgname The organization from which the instances will be deleted.
-t templateDefinitionId The template definition identifier of the instances to be deleted. See below for information on obtaining the templatedefinitionid
-start hrs Delete instances whose end (or start) time is hours_back before the current time. Hours_back is a floating point value so fractional hours can be specified. If not specified, the "epoch" is used.
-end hrs If provided, specifies the number of hours from start that defines the time range from which instances will be deleted. If not specified, the current system time used. This is a floating point value so fractional hours can be specified.
-delta hrs Break the time specified by start and end into segments of this amount of time, thereby allowing several small deletes to occur to prevent transaction timeouts. If not specified the instances are deleted in one operation. This is a floating point value so fractional hours can be specified.
-a Delete active (haven't completed) instances. Use with caution!
-v Verbose mode. Displays information about what is being deleted.

The templatedefinitionid can be determined using the following SQL query:

SELECT TEMPLATEDEFINITIONID FROM TEMPLATEDEFINITION WHERE TEMPLATEID IN (SELECT TEMPLATEID FROM TEMPLATE WHERE NAME LIKE '<template_name>');

See Also:
com.bea.wlpi.util.EJBHelper

WebLogic Integration

WebLogic Integration (WLI)