Mrinal,
The only methods you need to (and can, really) mark as AutoComplete are
the ones that implement your interface's contract which is registered in
COM+. This will cause your transaction to auto-commit or auto-fail
depending on whether or not an exception was thrown which was not handled in
your method.
If you place the attribute on other methods, then this could be a
problem, since you could end up committing the same transaction before you
really want to.
If you mark your class as NotSupported, then you might still want to
mark your methods with AutoComplete. If you are using JIT activation, then
you need to attach the AutoComplete attribute to your methods in order to
make sure your object is activated and deactivated on every call.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"Mrinal Kamboj" <mr***********@oracle.com> wrote in message
news:6u*************@news.oracle.com...
Hi ,
Need to get some basic info regarding AutoComplete Attribute in COM+ .
I am having a class with TransactionOption set to Required , now for this
class , can i mark all the methods with AutoComplete attribute ,
irrespective of the fact , whether i do implement Try .. Catch block or
not , as some of the methods are just meant for intermediary calculation
and are private , or i just need to mark one method that's public as
AutoComplete , as this one is supposed to be called from outside and it
internally calls all other methods .
Also , if i have class with TransactionOption set to NotSupported , then
does it makes sense to mark any methods as AutoComplete , as i think in
that case Transaction context doesn't even exists , but just wanted to be
sure .
any pointer regarding the same will be great .
thanks ,
Mrinal