OK this is going to assume that you are at least familiar with Entity Framework (if not then really climb out from
under a rock and go read up). In short, this is ORM and Query Provider wrapped up in one for use with managing the interaction of model code with a relational datastore. This isn't the only full(ish) featured ORM for .Net nor the first nor anything of a claim of "the best", whatever that actually means. However it is common and well supported (as a Microsoft product) but after a while, there's going to be a point where nontrivial solutions are going to run right up to the (frequent) areas where they didn't think out any extension points. In this series we'll be specifically looking to add tools to your kit that enable more flexible and supple designs and perhaps open up your thoughts to OO patterns that help manage complexity (in the context of a solution of using EF).
It's assumed we're dealing with an Entity Framework v6.1 or higher environment throughout this series. (v7 is a complete ground up rewrite so I'm sure we'll get our own new gotchas to cover).
- DomainEvents to the rescue for entity change notifications.
AKA
Making My Code That Cares About Orthogonal Concerns, Orthogonal
- DomainEvents Redux. Understand what's changed, not just when something's changed.
- CodeContracts, ISupportInitialize, and EF