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 / New Users / August 2007

Tip: Looking for answers? Try searching our database.

TransactionScope question

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Steve B. - 30 Aug 2007 15:37 GMT
Hi,

I'm building an application that performs some operations of several kinds :
file copy, IIS web site creation, etc...

Since if one of this operation fails, all others have to be rollbacked, I
started to look at the transactionscope class and IEnlistmentNotification
interface.

How can I know what objects in .Net framework implements such objects ? I
know ADO..net does, but what about DirectoryEntry, File.Copy, etc ?

I implemented manually the File.Copy to support transaction... but what a
pain ! Is there any namespace or class that can do the job for me ?

Thanks in advance,
Steve
Michael Nemtsev - 30 Aug 2007 15:51 GMT
Hello Steve B.,

I suppose your transacted file copy code looks like this one http://codebetter.com/blogs/sahil.malik/archive/2005/04/28/62604.aspx 
:)

The problem u are stublem is an issue in the modern development, because
there are no Resources Managers for the such things like file copy end etc.
The solution for this is the STM - software transacted memory, where we can
operate the set of memory block, like files or arrays, within transations

unfortunatelly there is no standart implementations yet

I suggest u to read this http://weblogs.asp.net/ralfw/archive/2007/07/03/software-transactional-memory-ma
king-multithreading-easier.aspx

to understand the deep of the problem :)

---
WBR,
Michael  Nemtsev [.NET/C# MVP] :: blog: http://spaces.live.com/laflour 

"The greatest danger for most of us is not that our aim is too high and we
miss it, but that it is too low and we reach it" (c) Michelangelo

S> Hi,
S>
S> I'm building an application that performs some operations of several
S> kinds : file copy, IIS web site creation, etc...
S>
S> Since if one of this operation fails, all others have to be
S> rollbacked, I started to look at the transactionscope class and
S> IEnlistmentNotification interface.
S>
S> How can I know what objects in .Net framework implements such objects
S> ? I know ADO..net does, but what about DirectoryEntry, File.Copy, etc
S> ?
S>
S> I implemented manually the File.Copy to support transaction... but
S> what a pain ! Is there any namespace or class that can do the job for
S> me ?
S>
S> Thanks in advance,
S> Steve
Steve B. - 30 Aug 2007 16:02 GMT
Mine works with File.Copy, but the idea is the same.
I found tha Vista use KTM for making disk and registry changes
rollbackable... but as my apps runs on W2K3, I can't rely on it (or will it
be available for wxp ?)

Thanks for the link, it seems to be a usefull reading.

> Hello Steve B.,
>
[quoted text clipped - 35 lines]
> S> S> Thanks in advance,
> S> Steve
Michael Nemtsev - 30 Aug 2007 17:08 GMT
Hello Steve B.,

Vista KTM is probably the part of the WinFS, what they did is just provide
the resource managers and/or compesators for this, imho

I don't thing that u need rely on KTM, just read the link I gave u and try
to used the 3rd party STM realization or I'd think about implementing compensators,
like we do in COM+ providing the rollback for non-transactable components

---
WBR,
Michael  Nemtsev [.NET/C# MVP] :: blog: http://spaces.live.com/laflour 

"The greatest danger for most of us is not that our aim is too high and we
miss it, but that it is too low and we reach it" (c) Michelangelo

S> Mine works with File.Copy, but the idea is the same.
S> I found tha Vista use KTM for making disk and registry changes
S> rollbackable... but as my apps runs on W2K3, I can't rely on it (or
S> will it
S> be available for wxp ?)
S> Thanks for the link, it seems to be a usefull reading.
S>
S> "Michael Nemtsev" <nemtsev@msn.com> wrote in message
S> news:3d9fba1a16698c9b980437b151b@msnews.microsoft.com...
S>
>> Hello Steve B.,
>>
[quoted text clipped - 45 lines]
>> S> S> Thanks in advance,
>> S> Stev

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.