SYSTEM AND METHOD FOR SUPPORTING RESOURCE ENLISTMENT SYNCHRONIZATION
First Claim
1. A system for supporting resource enlistment synchronization, comprising:
- an application server with a plurality of threads, running on one or more processors;
a transaction manager that manages a plurality of transactions, wherein each transaction is associated with at least one said thread, and the transaction manager operates to be associated with each of the plurality of threads;
a plurality of wrapper objects, wherein each wrapper object wraps a resource object of a plurality of resource objects, wherein the transaction manager maintains and communicates with each wrapper object of the plurality of wrapper objects to manage resource object enlistment requests from different said threads associated with different transactions;
wherein, upon receiving a request from a thread of the plurality of threads to enlist a resource object of the plurality of resource objects in a transaction, the transaction managerfirst checks with a wrapper object that wraps the resource object to see if there is a lock being held on the resource object by another said thread in another said transaction,if there is a lock, then allows the thread to wait and signal the thread once the lock is freed by the another said thread in the another said transaction,if there is no lock, then grants a lock to the thread and holds the lock until an owner of the thread delists the resource object, wherein the wrapper object is used to access the resource object for the thread.
0 Assignments
0 Petitions
Accused Products
Abstract
A system uses a transaction manager for supporting resource enlistment synchronization on an application server with a plurality of threads. This system also includes a plurality of wrapper objects, each of which wrapper object wraps a resource object associated with the application server. Upon receiving a request from a thread to enlist a resource object in a transaction, the transaction manager first checks with a wrapper object that wraps the resource object to see if there is a lock being held on the resource object by another said thread in another said transaction. If there is a lock, the transaction manager allows the thread to wait and signal the thread once the lock is freed by another said thread in another said transaction. Otherwise, the transaction manager grants a lock to the thread and holds the lock until an owner of the thread delists the resource object.
-
Citations
17 Claims
-
1. A system for supporting resource enlistment synchronization, comprising:
-
an application server with a plurality of threads, running on one or more processors; a transaction manager that manages a plurality of transactions, wherein each transaction is associated with at least one said thread, and the transaction manager operates to be associated with each of the plurality of threads; a plurality of wrapper objects, wherein each wrapper object wraps a resource object of a plurality of resource objects, wherein the transaction manager maintains and communicates with each wrapper object of the plurality of wrapper objects to manage resource object enlistment requests from different said threads associated with different transactions; wherein, upon receiving a request from a thread of the plurality of threads to enlist a resource object of the plurality of resource objects in a transaction, the transaction manager first checks with a wrapper object that wraps the resource object to see if there is a lock being held on the resource object by another said thread in another said transaction, if there is a lock, then allows the thread to wait and signal the thread once the lock is freed by the another said thread in the another said transaction, if there is no lock, then grants a lock to the thread and holds the lock until an owner of the thread delists the resource object, wherein the wrapper object is used to access the resource object for the thread. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9)
-
-
10. A method for supporting resource enlistment synchronization, comprising:
-
providing an application server with a plurality of threads, running on one or more processors; managing, via a transaction manager, a plurality of transactions, wherein each transaction is associated with at least one said thread, and the transaction manager operates to be associated with each of the plurality of threads; wrapping each resource object of a plurality of resource objects with a wrapper object in a plurality of wrapper objects, wherein the transaction manager maintains and communicates with each wrapper object of the plurality of wrapper objects to manage resource object enlistment requests from different said threads associated with different transactions; receiving a request from a thread of the plurality of threads to enlist a resource object of the plurality of resource objects in a transaction at the transaction manager; first checking with a wrapper object of the resource object, via the transaction manager, to see if there is a lock being held on the resource object by another said thread in another said transaction; if yes, allowing, via the transaction manager, the thread to wait and signaling the thread once the lock is freed by the another said thread in the another said transaction; if not, granting, via the transaction manager, a lock to the thread and holding the lock until an owner of the thread delists the resource object, wherein the wrapper object is used to access the resource object for the thread. - View Dependent Claims (11, 12, 13, 14, 15, 16)
-
-
17. A computer-readable storage medium, storing instructions for supporting resource enlistment synchronization, the instructions comprising the steps of:
-
providing an application server with a plurality of threads, running on one or more processors; managing, via a transaction manager, a plurality of transactions, wherein each transaction is associated with at least one said thread, and the transaction manager operates to be associated with each of the plurality of threads; wrapping each resource object of a plurality of resource objects with a wrapper object in a plurality of wrapper objects, wherein the transaction manager maintains and communicates with each wrapper object of the plurality of wrapper objects to manage resource object enlistment requests from different said threads associated with different transactions; receiving a request from a thread of the plurality of threads to enlist a resource object of the plurality of resource objects in a transaction at the transaction manager; first checking with a wrapper object of the resource object, via the transaction manager, to see if there is a lock being held on the resource object by another said thread in another said transaction; if yes, allowing, via the transaction manager, the thread to wait and signaling the thread once the lock is freed by the another said thread in the another said transaction; if not, granting, via the transaction manager, a lock to the thread and holding the lock until an owner of the thread delists the resource object, wherein the wrapper object is used to access the resource object for the thread.
-
Specification