简体   繁体   中英

Does calling a regular .net assembly from COM+ mean the benefits of COM+ are lost?

I have a vb6 component that hosted in com+ that makes several calls to a .net assembly on same machine to fetch data. This .net assembly is very simple and does not derive from ServicedComponent and is simply exposed as Com.

Does using a .net assembly in this way mean that the .net component is not getting any of the benefits of com+ pooling etc and making all my calls to it likely very slow as .net assembly getting recreated fresh each time?

Many Thanks

It depends on what the assembly is doing. COM+ gives you many advantages doing things like transaction management, context flow between machines, pooling, etc. However if this assembly of yours is simply reading a file or something like that, then it doesn't really matter if your VB6 DLL is hosted in COM+ or not.

Now if the .NET assembly is talking to a database or some such then yes, it becomes "enlisted" in the COM+ context and transaction (if any) and you are getting the benefits of COM+.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM