Don’t over architect software by trying to fit as many patterns and popular approaches in as possible

I can definitely relate to the tweet below 👇🏻. When I first started architecting software I was obsessed with complexity … Continue reading Don’t over architect software by trying to fit as many patterns and popular approaches in as possible

eShopOnWeb Architecture (15/16) – has a really nice example of the Interface Segregation Principle

We can see a nice example of the interface segregation principle in eShopOnWeb. For its repository interfaces eShopOnWeb have two … Continue reading eShopOnWeb Architecture (15/16) – has a really nice example of the Interface Segregation Principle

eShopOnWeb Architecture (13/16) – has some single implementation interfaces

eShopOnWeb has a couple of its service classes (BasketService and OrderService) implement corresponding interfaces (IBasketService and IOrderService). These interfaces have … Continue reading eShopOnWeb Architecture (13/16) – has some single implementation interfaces

eShopOnWeb Architecture (12/16) – uses the repository and specification pattern

eShopOnWeb uses the repository pattern over Entity Framework ((I’m not getting into this debate again 😉). When we use this pattern we … Continue reading eShopOnWeb Architecture (12/16) – uses the repository and specification pattern

eShopOnWeb Architecture (10/16) – has unit tests which test very low level implementation details

eShopOnWeb has some really low level tests which IMHO provide low or no value in terms of being able to … Continue reading eShopOnWeb Architecture (10/16) – has unit tests which test very low level implementation details

eShopOnWeb Architecture (9/16) – uses the Aggregate root pattern to ensure child objects are not manipulated out of context

Aggregate roots are a central concept in Domain Driven Design. The idea is pretty simple and refers to how certain entities … Continue reading eShopOnWeb Architecture (9/16) – uses the Aggregate root pattern to ensure child objects are not manipulated out of context

eShopOnWeb Architecture (8/16) – uses in memory caching to avoid sending unnecessary queries to the DB

To improve performance eShopOnWeb uses IMemoryCache to implement in memory caching to prevent queries being sent to the Database for … Continue reading eShopOnWeb Architecture (8/16) – uses in memory caching to avoid sending unnecessary queries to the DB

eShopOnWeb Architecture (7/16) – encapsulates navigation collections so consumers can’t edit them directly

Another example of encapsulation but this time on the navigation collection level is seen in eShopOnWeb with the use of … Continue reading eShopOnWeb Architecture (7/16) – encapsulates navigation collections so consumers can’t edit them directly

eShopOnWeb Architecture (6/16) – uses private setters and non default constructors to support encapsulation which helps keep the model valid

eShopOnWeb has some really nice examples of encapsulation. The particular example below is the CatalogItem class. Click on the image … Continue reading eShopOnWeb Architecture (6/16) – uses private setters and non default constructors to support encapsulation which helps keep the model valid