The lock manager handles event sequencing locks. You can use the esAdmin command
to list, delete, or unlock any lock in the lock manager.
The lock manager supports two operations on event locks:
- Lock – The lock operation attempts to acquire a lock and stores the lock
request in a database. After a lock is granted, processing resumes for the
invocation that requested the lock.
- Unlock – The unlock operation releases the current lock and grants the
lock to the next lock request.
Requests for the same lock are put into a queue in the order in which
they are received. Locks are persisted to the default
WebSphere Process Server database
and data source to ensure they can be recovered in the case of a server failure.
The
esAdmin command enables you to administer the active
and queued locks currently in the lock manager. The following sections provide
more detail on using
esAdmin.
Note: If you are using partitioned
databases, run the esAdmin command once for each deployment
target. In a clustered environment, you can run it on any cluster, but running
it on the deployment manager can produce unpredictable results.
Listing locks
The esAdmin command
can list all active and queued locks in the lock manager, or only those locks
associated with a specific module, component, or method.
Use one of
the following methods with
esAdmin:
The command returns output that looks like the following:
Table 1. Sample output from esAdmin listLocks commandLock Id |
Sequence Id |
Owner Id |
Module |
Component |
Method |
System Message Id |
7564504 |
2 |
695376 |
CustMod |
CustComp |
createCust |
A09- 427BE_5002 |
7564504 |
3 |
232757 |
CustMod |
CustComp |
createCust |
ADF- 053RT_5004 |
In the output above, the sequence ID is the order in which the lock
requests are queued; the lowest number in the sequence currently holds the
lock. The system message ID specifies the ID for the corresponding service
integration bus message; you can use this information to correlate lock requests
with the messages on the destinations.
Releasing locks
Use the
esAdmin command
to release a single lock, as follows:
esAdmin unlock lockId
where
lockId is
the unique lock ID returned by the
esAdmin listLock or
esAdmin
listAll command.
This command is useful when you encounter
a deadlock; you can release the lock that is deadlocked and grant it to the
next lock request in the queue.
Deleting locks
If you need to delete one or more
locks, first stop the module associated with the lock. Then, use the esAdmin
command to delete the lock from the database, as follows:
esAdmin deleteLocks moduleName
You
must restart the module in order for the destinations to resume processing
event messages.
Use the esAdmin deleteLocks command with caution. All
locks in the specified module are deleted from the lock manager database.
Last updated: Wed 06 Dec 2006 07:08:08
(c) Copyright IBM Corporation 2005, 2006.
This information center is powered by Eclipse technology (http://www.eclipse.org)