摘要:
The present invention provides a method and system for multi-threaded processing that is an improvement over conventional systems. The system of the present invention comprises multiple threads of execution, multiple apartments, shared data, and a concurrency management component. The threads of execution run independently and each occupy one apartment. The apartments contain objects that have methods to perform operations. The shared data contains data that is accessible by all threads within the process. The concurrency management mechanism performs processing so that the multiple threads can execute concurrently in a reliable and robust manner. In an alternative system of the present invention, the threads are separate from the apartments and the threads execute within the apartments to perform processing. After performing the processing, the thread exits the apartment so that the apartment may be occupied by another thread.
摘要:
The present invention provides a method and system for multi-threaded processing that is an improvement over conventional systems. The system of the present invention comprises multiple threads of execution, multiple apartments, shared data, and a concurrency management component. The threads of execution run independently and each occupy one apartment. The apartments contain objects that have methods to perform operations. The shared data contains data that is accessible by all threads within the process. The concurrency management mechanism performs processing so that the multiple threads can execute concurrently in a reliable and robust manner. In an alternative system of the present invention, the threads are separate from the apartments and the threads execute within the apartments to perform processing. After performing the processing, the thread exits the apartment so that the apartment may be occupied by another thread.
摘要:
A computer method and system for passing a pointer to an interface from a server process to a client process. In a preferred embodiment, the server process instantiates an object that has multiple interfaces. The server process identifies an interface to pass to the client process and creates a stub object for receiving a request to invoke a function member of the interface and for invoking the requested function member upon receiving the request. The server process then sends an identifier of the stub to the client process. When the client process receives the identifier of the stub, it instantiates a proxy object for receiving requests to invoke a function member of the interface and for sending the request to the identified stub. The client process can then invoke the function members of the interface by invoking function members of the proxy object. The proxy object sends a request to the identified stub. The identified stub then invokes the corresponding function member of the interface.
摘要:
A computer-based method and system for accessing objects of different thread types in a single process. The system provides single-threaded apartments (STAs) for loading apartment-threaded objects and a multi-threaded apartment (MTA) for loading free-threaded objects. Each STA has a single thread, and the MTA has multiple threads. When an STA thread requests to access a free-threaded object, the system creates an MTA thread and requests the MTA thread to instantiate the free-threaded object. The STA thread then receives a marshalled pointer to the free-threaded object and unmarshals the received pointer. The STA thread then accesses the free-threaded object using the unmarshalled pointer so that the MTA thread accesses the free-threaded object on behalf of the STA thread. When an MTA thread requests access to an apartment-threaded object, the system creates an STA thread and requests the STA thread to instantiate the apartment-threaded object. The MTA thread then receives a marshalled pointer to the apartment threaded object and unmarshals the received pointer. The MTA thread then accesses the apartment-threaded object using the unmarshalled pointer so that the STA thread accesses the apartment-threaded object on behalf of the MTA thread.
摘要:
A method and system for delayed registration of a remote protocol for communicating between a client computer system and a server computer system. The server computer system has a communications process that registers a plurality of protocols. When the client process needs to communicate with the server process, it sends a request to the communications process along with an indication of the protocols that it supports. The communications process selects a protocol that is supported by both the client computer system and the server computer system and directs the server process to register that protocol. The communication process provides the server endpoint for that protocol to the client process which can then communicate directly with the server process.
摘要:
A method and system for preventing incorrect information from corrupting server object information maintained by a client machine. A DCOM client machine is provided with object reference information for accessing remote objects. DCOM unmarshals the information into server object information, including an object identifier and string bindings of a remote resolver through which the client machine may contact the remote server to obtain string bindings for that remote object. Each resolver string bindings received by a client machine are compared against known resolver string bindings and each unique permutation of string bindings is associated with a unique machine identifier locally generated therefor. Each object identifier is paired with its corresponding unique machine identifier so that all references to a remote object include the identity of the machine on which the object was created.