Managing an Engine Database

Growth of the Database

As with any of the enterprise databases used by your workflow application, the engine database can grow in size. The current state tables grow and shrink in proportion to the number of sessions, process instances, activities, process attributes, and timers that exist at any one time. The registration tables are typically quite small, but grow in proportion to the number of distributions or aliases you register with the engine.

The history log, however, because it accumulates historical data, can grow quite large as time goes on, eventually reaching your database storage limit. You must therefore establish a set of procedures for monitoring and limiting the growth of the history log. The following suggestions might prove useful:

Log only the minimum historical data that you will need for process execution analysis.

See “How to Dynamically Modify Database Logging” on page 115 for history logging options.

Maintain an archive history log database.

When rows in your history log tables are sufficiently aged, you can delete them from the engine database and transfer them to an archive database. For example, if your system does not make use of long-running process instances, you might want to periodically transfer all rows in your history log that correspond to process instances that terminated more than two months ago.

Failure of the Database

For any number of reasons, the engine database might fail. If the engine cannot access the database (that is, it cannot write to the database), then it raises an exception and transitions to STANDBY state in which it stops process execution. Engine exceptions are written to the primary engine unit’s log file and to the iIS Console Alarms window. See Chapter 7, “Troubleshooting,” for more information on exceptions.

Recovering Data

When starting an engine, you can choose to recover or lose any existing current state, registration, or history log database tables, as long as you are not starting the engine for the first time. The various startup options are described in “How to Start an Engine” on page 110. When you recover the current state tables you also recover the registration tables.

Chapter 4 Managing Engines 125

Page 125
Image 125
Sun Microsystems 3 manual Growth of the Database, Failure of the Database, Recovering Data