Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MTS Component instance not getting destroyed. 2

Status
Not open for further replies.

fourguys

Programmer
Jun 16, 2000
3
0
0
IN
Hi,<br>&nbsp;&nbsp;&nbsp;I have created a component(dll) in VB6.0 for my application and the component is refering to ADO objects. I created a package in MTS and added this component. When this component is accessed by my client application I find the components icon rotating in MTS explorer. Thats fine..<br>My problem is, even after i stop the client application i find the component icon rotating in MTS explorer, which means( i suppose) that the instance of the component is still not destroyed. What should i do to avoid this. Please help.<br><br>
 
Hi!!<br><br>The thing with MTS is that is keeps an instance of the object alive if anyoneelse should need it. There is a place in the MTS that defines the time that an instance shall stay alive without being used before it gets destroyed!<br>In the properties of the package in which the component is installed choose Advanced! Set the &quot;Shut down after being idle &quot; to 0 minutes! I suppose this should do the trick!!<br><br>Why do you want it to be destroyed at once?? Its on of the main thing, as connection pooling, of the MTS!!<br><br>
 
Howdy,<br><br>Unfortuniately I have to disagree with Nikolay: the object you created still exists indeed (Object Pooling is NOT, I repeat NOT implemented in MTS v2.0!!!!!! (you can find this in the helpfile of MTS v2.0 SP1)<br><br>I think the problem you have is that not all objects created in the component are not cleanly 'destroyed'. You have to close them all: Set myADOObject = Nothing, etc. If you cleanly destroy all objects, the dll will stopp turning (believe me: placing a dll in MTS is easy: making it work as you want (only initialize objects when you need them, and destroy them when not needed anymore) is the hardest task)<br><br>A tip: install MTS and VB on the same NT machine. Install the VB dll into MTS and debug your project from within VB (create another 'dummy' project inside the dll project with forms and a reference to your dll): now you can see if all objects are cleanly destroyed and if your component will be closed in MTS.<br><br>Regards and Good luck,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Kees
 
Hi,<br>&nbsp;&nbsp;&nbsp;&nbsp;Thanku Nikolaj & Kees. I tried out the suggestions given by kees and found that it was working. once again thanku.<br><br>fourguys.
 
Hi Again!<br><br>Im sorry If i misinformed you fourguys!! Obivously the Object Pooling feature is not a part of the MTS 2.0 Release!<br><br>Nikolaj<br>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top