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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Unique ID of com object process

Status
Not open for further replies.

safraser

Programmer
Apr 12, 2001
76
NZ
I'm really sorry, I know this type of thing as been asked before but I've not seen a complete answer to my problem.

I've had an existing project dropped on my desk with a problem, the original developer died last year so it has fallen to me to fix this issue. It has worked fine with a single user in trials, but now that it's been pushed out to multiple users it's getting nasty. I have a feeling that there is some bad design here, but my task is to fix it right now

Basically, have a Web Service that is accessing another application via com.
What we are finding is that the process list is just getting fulled up with instances of this com process and in very quick succession causing the server to just grind to a halt.
The service appears to be doing everything it can to clean up the com references using it's exposed methods but the objects themselves just don't go away.

I've tried Process.GetProcessesByName() but it has a static name and I don't want to kill off the wrong users process.

So my question is, is there away to uniquely identify each instance, either when created or some time after
 
Thanks, pretty much what I did in the end. Also created a wrapper class that implemented IDisposeable, then used Runtime.InteropServices.Marshal.RealeasecomObject which seems to be killing the process off. The just altering the web service code destroy the object
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top