Groups | Blog | Home
all groups > dotnet component services > february 2004 >

dotnet component services : Transactions in COM+ with Non-Transactional Components


andre.henriksson NO[at]SPAM knowit.se
2/26/2004 7:31:22 AM
Hi,

I'm a bit confused over how transactions work with managed code
components and .Net COM+ components. All papers and postings I've
found say that if a .Net Serviced Component calls a non-serviced
component any transactions will be ignored started from the serviced
component.

However, today I tested the following:

..Aspx-page

calls

Serviced Component (Transaction required)

calls

MS Data Access Building Block (SQLHelper to execute SPs)

calls

Database

What the papers say is that if I make for instance several inserts
into the database from the Serviced Component through the SqlHelper
class and finally calls ContextUtil.SetAbort in the Serviced Component
non of the inserts should be rollbacked. But they are, how come?

enrico sabbadin NO[at]SPAM infinito
2/26/2004 6:44:09 PM
non-configured .net components run in the context of the caller confgured
component .. they
are like inline code as far as com+ is concerned (think about ado.net : it
is not a configured component , however it has the "transaction flow" (it's
ado.net doing the updates basically , isnt' it ?))
This is exactly the same in vb6 /COM ..
as a fact one generally puts business objects in com+ and leave data access
objects as simple components).

I've read that MS says that this behaviour might change in the future, I
just know that if it does it break thousands of apps.

HTH

[quoted text, click to view]

AddThis Social Bookmark Button