COM components that run under the control of the MTS Executive are called MTS components. In COM+, they are referred to as COM+ Applications. MTS components are in-process DLLs. MTS components are deployed and run in the MTS Executive which manages them. As with other COM components, an object implementing the IClassFactory interface serves as a Factory Object to create new instances of these components. MTS inserts a Factory Wrapper Object and an Object Wrapper between the actual MTS object and its client. This interposing of wrappers is called interception. Whenever the client makes a call to the MTS component, the wrappers intercept the call and inject their own instance-management algorithm called the Just-In-Time Activation into the call. The wrapper then makes this call on the actual MTS component. Interception was considered difficult at the time due to a lack of extensible metadata. In addition, based on the information from the component's deployment properties, transaction logic and security checks also take place in these wrapper objects. For every MTS-hosted object, there also exists a Context Object, which implements the IObjectContext interface. The Context Object maintains specific information about that object, such as its transactional information, security information and deployment information. Methods in the MTS component call into the Context Object through its IObjectContext interface. MTS does not create the actual middle-tier MTS object until the call from a client reaches the container. Since the object is not running all the time, it does not use up a lot of system resources. As soon as the call comes in from the client, the MTS wrapper process activates its Instance Management algorithm called JITA. The actual MTS object is created "just in time" to service the request from the wrapper. And when the request is serviced and the reply is sent back to the client, the component either calls SetComplete/SetAbort, or its transaction ends, or the client calls Release on the reference to the object, and the actual MTS object is destroyed. In short, MTS uses a stateless component model. Generally, when a client requests services from a typical MTS component, the following sequence occurs on the server :
write the component's changed state, if any, back to the database
close and release the database connection
vote on the result of the transaction. MTS components do not directly commit transactions, rather they communicate their success or failure to MTS.
It is thus possible to implement high-latency resources as asynchronous resource pools, which should take advantage of the stateless JIT activation afforded by the middleware server.