Queued method invocations on distributed component applications
First Claim
1. An object runtime services system for running objects on a computer, the objects having interfaces with methods for calling by clients, the system comprising:
- a recorder operating to intercept a plurality of method invocations issued in a transaction by a client to invoke methods of an object, and further operating to record the method invocations as a message;
a message queue for queuing the message to a later time;
a player operative to extract the method invocations from the message, and issue the method invocations to the object at the later time, whereby the client asynchronously invokes the methods of the object.
2 Assignments
0 Petitions
Accused Products
Abstract
An object runtime architecture allows method invocations to be made on either a synchronous, real-time basis or a queued basis using the normal call semantics of an object model. The object runtime architecture provides a proxy of an object with a method invocation recorder for receiving method calls of a client on the object, and marshaling the method calls into a message for sending to a queue associated with the object. The object runtime architecture further provides a listener for dispatching the message from the queue to a player which uses a stub to unmarshal the message in order to issue the method calls to the object. The object runtime architecture thus decouples the client and objects lifetimes and availability, without requiring explicit programming of the client and object to perform message queuing. Accordingly, with no modification of the object'"'"'s interface structure or code, the same object can be used in either a real-time or queued environment. This allows the decision between real-time or queued method invocations to be made much later than at development of the object, such as at run-time creation of the object.
-
Citations
14 Claims
-
1. An object runtime services system for running objects on a computer, the objects having interfaces with methods for calling by clients, the system comprising:
-
a recorder operating to intercept a plurality of method invocations issued in a transaction by a client to invoke methods of an object, and further operating to record the method invocations as a message;
a message queue for queuing the message to a later time;
a player operative to extract the method invocations from the message, and issue the method invocations to the object at the later time, whereby the client asynchronously invokes the methods of the object. - View Dependent Claims (2, 3)
a proxy operating to receive the method invocations by the client and marshal parameters of the method invocations.
-
-
3. The system of claim 1, wherein the player further operates to issue the method invocations to the object in a new transaction.
-
4. A process for a client to access object methods, the process comprising:
-
designating whether an object is to receive method calls on a real-time or queued basis;
calling methods of an object by a client in accordance with a call semantic of an object model;
if the object is designated to receive method calls on a real-time basis, issuing the method call to the object and causing the client to block until the call returns from the method;
if the object is designated to receive the method calls on a queued basis, performing the steps;
recording the method call in a message;
sending the message to a queue;
causing the client to continue execution;
after the client continues execution, retrieving the message from the queue; and
issuing the method call recorded in the message to the object.
-
-
5. An object execution system supporting method invocation delivered via a queued message, the system comprising:
-
an object configuration store containing object properties information representing properties of an object class executable in the system, the object properties information designating the object class as supporting queued method invocation;
a method invocation recording facility operative responsive to request of a client program to supply method invocations recorders for object instances of object classes designated as supporting queued method invocations;
a first method invocations recorder supplied by the method invocation recording facility at request of the client program for an instance of the object class, the first method invocations recorder operating in response to a plurality of method invocations by the client program for the object class instance to cause a data stream representation of the method invocations to be marshaled into a method invocations message for submission into a message queue associated with the object class;
a method invocation play-back facility operative responsive to queued method invocations messages to supply method invocation players for object instances of object classes designated as supporting queued method invocations;
a first method invocation player supplied by the method invocation play-back facility in response to the method invocations message queued to the message queue associated with the object class, the first method invocations player operating in response to the method invocations message to unmarshal the data stream representation and issue the method invocations to the object class instance. - View Dependent Claims (6)
-
-
7. In a computer system, a method of asynchronously remoting method invocations of a client program to a program component via a message queue, the method comprising:
-
providing a reference for use by the client program to invoke methods on the program component;
responsive to a client program issuing a set of method invocations for the queued component, marshaling data for the method invocations of the set into a message;
upon release of the reference by the client program, submitting the message to the message queue associated with the program component; and
at a later time of processing the message from the message queue, unmarshaling the data for the method invocations from the message, and issuing the set of method invocations to the queued component. - View Dependent Claims (8, 9)
-
-
10. In a distributed computing system where a client program and a server queued component are run on at least one computing machine, a method of transactional queued invoking by the client program of methods on the server queued component, the method comprising:
-
initiating a first transaction for encompassing processing of the client program;
on request of the client program for a reference to the server queued component, creating a first method invocation recorder in the first transaction and returning a reference for invoking methods of the first method invocation recorder to the client program;
on each of a set of method invocations of the client program made using the reference for invoking methods of the first method invocation recorder, recording by the first method invocation recorder data of the set of method invocations into a method invocations message;
upon committal of the first transaction, submitting the method invocations message into a message queue associated with the server queued component;
creating the server queued component for processing any method invocations recorded in the method invocations message in a second transaction;
retrieving the method invocations message from the message queue within the second transaction;
invoking a set of methods of the server queued component in the second transaction per the recorded set of method invocations.
-
-
11. A computer-readable medium having thereon a computer-executable method invocation queuing system program comprising:
-
a queued component recorder constructor operating on request of a client program to obtain a queued component reference to create a method invocation recording component and return a reference for such method invocation recording component to the client program;
a first method invocation recording component created by the queued component recorder constructor responsive to a first request of a client program to obtain a first reference for a first queued component, the first method invocation recording component having an interface and methods for receiving method invocations made by the client program for the first queued component using the reference, the first method invocation recording component operating in response to the client program'"'"'s method invocations using the reference to marshal data of the method invocations into a data stream of a message and submit the message into a queue associated with the first queued component. - View Dependent Claims (12)
a queued method invocations playing component operating to retrieve the message from the message queue, the queued method invocations playing component further operating in response to the message to unmarshal the data stream, and to invoke methods on the first queued component in accordance with the marshaled client program'"'"'s method invocations.
-
-
13. A computer-readable medium having thereon a computer-executable method invocation queuing system program comprising:
a queued method invocations playing component operating to retrieve a method invocations message from a message queue associated with a first queued component, the queued method invocations playing component further operating in response to a message containing a data stream representative of a set of method invocations from a client program for methods of the first queued component to unmarshal the set of method invocations from the method invocations message and to invoke methods on the first queued component based on the unmarshaled set of method invocations.
-
14. A process for a client to access object methods, the process comprising:
-
designating whether an interface is to receive method calls on a real-time or queued basis;
calling methods of the interface by a client in accordance with a call semantic of an object model;
if the interface is designated to receive method calls on a real-time basis, issuing the method call to the interface and causing the client to block until the call returns from the method;
if the interface is designated to receive the method calls on a queued basis, performing the steps;
recording the method call in a message;
sending the message to a queue;
causing the client to continue execution;
after the client continues execution, retrieving the message from the queue; and
issuing the method call recorded in the message to the interface.
-
Specification