how to implement unitofwork pattern when using subsonic 2.1(Repository pattern) ?
- by ROHITH
I am using subsonic repository pattern(2.1) for asp.net mvc application.In my application,there are many repositories like categoryRepository,Blogrepository etc.Inside each of this repository i am calling subsonic's DB.Select().From()...ExecuteReader() and then loading domain objects from those reader.
In the controller action i make multiple calls from these repositories for e.g.
List<IBlog> blogs=_blogRepository.GetHottestBlogs();
List<ICategory> categories=_categoryRepository.GetAll();
do i have to implement any unitofwork pattern for this ?.My doubt is that how subsonic performs each operation DB.Update/Insert/Select .Is a TransactionScope is enough for batch update or do i have to use SharedDbConnectionScope to get better performance?