>I was aware that this happened with multiple interfaces, but not with a single interface referenced by multiple clients simultaneously. If this is the case, what manages thread affinity for a given client? I thought that MTS was needed to take care of the issue.
Not in SP3. MTS doesn't have anything to do with this at all - it's just
another multi-threaded client to a VFP COM object.
As I pointted out to Jim, I don't know exactly what the VFP runtime does behind
the scenes. All I know is that the memory overhead is not enough to cause new
full copies of the runtime to load - only global memory copies (about 600k
worth or so).
COM manages the thread isolation. Apartment Model Threading handles the
synchronization issues by guaranteeing every component running on the same
thread that it was created on. Every component gets it's own thread, but
as far as it's concerned it owns that thread. TLS provides the storage
of separated data - your thread affinity (not really but as close as you
get).
+++ Rick ---