PRB: Server Stops Responding When You Call Microsoft Transaction Server Component Under Active Server Pages (260075)
The information in this article applies to:
- Microsoft Internet Information Server 4.0
- Microsoft Visual Basic Professional Edition for Windows 6.0
- Microsoft Visual Basic Enterprise Edition for Windows 6.0
This article was previously published under Q260075 SYMPTOMS
When you call a Microsoft Transaction Server (MTS) component from a non-Microsoft Transaction Server component that is
- running under Microsoft Active Server Pages (ASP)
-and-
- written in Microsoft Visual Basic
then your server may stop responding to ASP requests when it is placed under stress.
CAUSE
This behavior can happen if the calling component creates the second component through the use of CreateObject, instead of through the object context's CreateInstance method.
A call to Server.CreateObject always creates an MTS thread with a context wrapper. Therefore, the first object is created on an MTS thread and ends up creating a second object, which is an MTS object. CreateInstance should be used when you create an MTS object from an object in Microsoft Transaction Server.
Another way to avoid this problem is to configure the calling component into an MTS server package so that it will start in a different process than if it were created in Inetinfo.exe's process space.
RESOLUTION
Because the calling component is running under ASP, it has access to all of the ASP properties and methods. Instead of creating the component using CreateObject, you can use the CreateInstance property of the ObjectContext object. For an example of how to accomplish this, see the example in the "More Information" section.
STATUS
This behavior is by design.
REFERENCES
Ted Pattison provides good information on this topic in his book Programming Distributed Applications with COM and Microsoft(r) Visual Basic(r) 6.0 (pages 284-288) and in "Creating Objects Properly in an MTS App" in the August 1999 edition of the Microsoft Independent Developer.
Modification Type: | Major | Last Reviewed: | 11/18/2003 |
---|
Keywords: | kbprb kbScalability KB260075 |
---|
|