Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Component Services / May 2005

Tip: Looking for answers? Try searching our database.

Strange behaviour with autocomplete and exceptions

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Isidoro de la Cierva - 12 May 2005 16:58 GMT
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.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.