Windows XP SP2
NET 1.1
C#
Using client/server COM+ with object pooling and JIT enabled. Typical
test program with client being a windows form and server a windows
library class derived form serviced component, with server activation.
Autocomplete attribute in the method of the server being called, the
method does nothing, just throws an Application exception. Overrided
CanBePooled to return true. Well, the object in the pool is still
activated after the method return (eventtracking enabled to monitor the
pool). If the server method doesnt throw an exception, the behaviour is
the expected and the counter of activated objects is decremented.
The thing that I cant understand is that this only happens when the
method of the server is member of a public interface (the server then
derives from serviced component and the interface being implemented).
If I dont use interfaces, the object is deactivated. Using transactions
or implementing manually the activation/deactivation doesnt change
anything. Any ideas?
Thanks in advance,
Isidoro de la Cierva
Klaus H. Probst - 16 May 2005 22:00 GMT
What exception are you getting? Is it the "transaction was already aborted or
was in the process of aborting" one?
What is the transaction mode setting for the component being called?
Requires transaction/supports/etc?

Signature
Klaus H. Probst, MVP
http://www.simulplex.net/
> Windows XP SP2
> NET 1.1
[quoted text clipped - 17 lines]
> Thanks in advance,
> Isidoro de la Cierva
Isidoro de la Cierva - 17 May 2005 09:55 GMT
The exception I'm getting is the same that I'm throwing, that's
correct. Transaction mode none. I'm using the [Autocomplete] attribute,
but it fails to deactivate the object when an exception is thrown and
there is an interface defined for the method being called. Putting
Transaction mode Required doesn't fix it. My problem is that the object
is not being deactivated when an exception is throwned and the client
has to call explicitly Dispose after each call.