SSW Blog

A group of enterprise software developers specializing in Microsoft solutions

You are here: Home / .NET / SSW Data Onion – Helping you Simplify your Data Layer

SSW Data Onion – Helping you Simplify your Data Layer

August 17, 2016 By Adam Cogan Leave a Comment

At SSW we build software for a large range of clients, from start ups to massive enterprises and even our own internal projects. We care that the software we build is secure, maintainable and testable.

Successful devs use great tools, great frameworks, and follow best practices. Choosing great tools like ReSharper and Octopus Deploy is easy, but many developers struggle with architecture decisions for their .NET projects. I recommend that developers follow the Onion Architecture. One of the most common pain points is the right way to implement Data Access using the Repository and Unit of Work patterns.

Implementing these enterprise data access patterns involves lots of complex up-front setup, and once implemented the plumbing code needs to be maintained.

To solve this problem we created SSW Data Onion. Data Onion makes it easy to get your Data Access Layer right and keep it up to date as your schema changes. It also saves you from spending your first sprint building the plumbing. You simply add and configure the NuGet packages, and get onto adding value. Once Data Onion is up and running, a lot of technical debt is removed because it saves you from ongoing maintenance of your repository plumbing. You simply update the domain entities, and voila – Data Onion refreshes your repositories.

data-onion
Figure: TT templates read your domain model and generate DBContext, Repository Interfaces and Repository Implementations.

So add SSW Data Onion to your projects to give you testable, maintainable data access using enterprise best practices!

We use it on most of the projects we build and when running mentoring/training for clients. Of course it also underpins our intensive 9 week training course, FireBootCamp.

To add SSW Data Onion to your solution, follow the step-by-step tutorial on the Data Onion website and watch as your data layer is generated for you.

Some of the other cool things about SSW Data Onion are,

  • its Unit of Work pattern supports multiple databases and supports saving across databases in a single transaction
  • it works with your choice of IOC container
  • it leaves you in control. You can use our templates out of the box or, for the ultimate flexibility, edit the supplied templates to completely customize the generated code
  • All generated class are partial – which provides you with clearly defined places to put you own code and extensions
  • Even if you don’t want to use the repository pattern, SSW Data Onion provides a tt template to generate the DBSet entries in your EF DbContext class.
  • Support for checking the DB schema with SqlVerify. This checks you DB schema for unexpected schema changes, for example if your client has manually modified a column type in their production database.

I hope you find that SSW Data Onion takes the pain out of writing and maintaining an enterprise data layer.

I’m happy it’s progressed from an internal tool to something you guys can use.
So whether you are a junior developer just starting out, and you want to build a maintainable and testable solution, or you are an experienced consultant who hates writing the same boiler plate code on every project, SSW Data Onion gives you best practices without spending hours and hours building code-generation templates.

Try SSW Data Onion today
http://sswdataonion.com – I’d love to know your thoughts.

 

< First posted on Adam Cogan’s Blog on Apr 8 2015 >

Share with someone

Filed Under: .NET, Data Onion Tagged With: Data Access, Data Access Layer, Data Onion, DBSet entries, EF DbContext class, NuGet, Octopus Deploy, Onion Architecture, ReSharper, SqlVerify, Unit of Work

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About SSW

We are a group of enterprise software developers specializing in Microsoft solutions that today build on top of Angular, React, Azure, Azure DevOps, SharePoint, Office 365, .NET Core, WebAPI, Dynamics 365 and SQL Server and we have been delivering awesome solutions for over 25 years for more than 1,000 clients in 15 countries.

Fire Boot Camp - 9 Weeks Intensive .Net Developer Training

Dev Super Powers - Meet your superhero from the Microsoft Stack

Original Blogs

  • Adam Cogan
  • Anthony Ison
  • Brendan Richards
  • Jason Taylor
  • JK
  • Matthew Wicks
  • Mehmet Ozdemir
  • Ulysses MacLaren
  • William Liebenberg

Follow Us

  • Email
  • Facebook
  • Instagram
  • LinkedIn
  • Twitter
  • YouTube

SSW / SSW TVFollow

SSW / SSW TV
SSW_TVSSW / SSW TV@SSW_TV·
28 Feb

We are excited to announce that our new office in Newcastle is now open!

Join us for finger food, drinks and a chance to meet the team on March 12. @AdamCogan will also do a short talk for #developers ''7 Simple Steps to Building your Profile'': RSVP: https://t.co/MdIool2Za9

Reply on Twitter 1366158662612508686Retweet on Twitter 13661586626125086865Like on Twitter 13661586626125086865Twitter 1366158662612508686
SSW_TVSSW / SSW TV@SSW_TV·
19 Feb

Meet Jean Thirion! Jean is an SSW Solution Architect & Angular trainer. If you want to learn Angular, or you just need some new tricks & best practices - this is the course for you! Join our #ONLINE course in March. Early bird discount finishes soon!
➡️ https://t.co/pC09oij0Ji

Reply on Twitter 1362658209627004930Retweet on Twitter 1362658209627004930Like on Twitter 13626582096270049303Twitter 1362658209627004930
Retweet on TwitterSSW / SSW TV Retweeted
mattgoldmanMatt Goldman #BlackLivesMatter@mattgoldman·
6 Feb

Automagic Tenant Config for Mobile Apps

Check out my blog post:
https://t.co/3kisEtO0ly

#MobileApps #MobileDev #XamarinForms

Reply on Twitter 1358190776467947520Retweet on Twitter 13581907764679475204Like on Twitter 13581907764679475207Twitter 1358190776467947520
Retweet on TwitterSSW / SSW TV Retweeted
jasontaylordevJason Taylor@jasontaylordev·
18 Jan

I'm looking forward to running a 2-day workshop on Clean Architecture with #Net5 at #NDCLondon next week! See you there!😃
@NDC_Conferences
https://t.co/Ak5EOgak1P

Reply on Twitter 1351294683926781952Retweet on Twitter 13512946839267819527Like on Twitter 135129468392678195228Twitter 1351294683926781952
SSW_TVSSW / SSW TV@SSW_TV·
20 Jan

We're experiencing technical difficulties with our live feed widget, please join us for Matt Goldman's talk here until it's up and running! https://t.co/gdJJdtvEb5

Reply on Twitter 1351795851933446144Retweet on Twitter 13517958519334461441Like on Twitter 13517958519334461441Twitter 1351795851933446144
Load More...

Recent Posts

  • The 5 Technologies that Will Change Everything in the Next Decade
  • The Sunk Cost Fallacy
  • How to Delegate Effectively (Orders and Enrolment)
  • Power BI – The Six Reports Every Consultancy Should Have
  • Seven Tips to Being a Great Product Owner

Contact Sales

Australia
+61 2 9953 3000

China
+86 571 8517 8910

Contact Us

Copyright © 2021 SSW. All Rights Reserved.