Repository and Unit of Work Patterns
摘要
In this chapter, you are going to learn about two critical patterns that exist which should be on the radar of every database developer, whether you are using Entity Framework or not. The good news is that EF implements its own unit of work (UoW) and repository (Repo) pattern work, so if you don’t do anything, you already benefit from the default implementations. The bad news is that EF is sometimes not everything that you need when implementing your solutions, but isn’t that the truth for any custom solution? After all, that’s why we get to be engineers, and part of what makes our work so fun.