I'm starting a new project (non-corporative) and I want to know how would be a great architecture nowadays.
What I'm planning for now is to use:
- ASP.NET MVC 4.0
- SQL Server 2008 or 2012
- EF 5.0 under .NET 4.5, with Dapper
- Implementation of Repository pattern (this one http://code.google.com/p/ef4prs/)
- DI with Autofac
- Automapper
- WCF Service Layer (for future mobile implementation)
Checking the flow (correct me if something is wrong): Controller calls ApplicationService, that calls a BusinessLayer, that calls DAL with UnitWork/Repository, that execute queries over EF or Dapper (is it correct to query Dapper from a specific method at Repository?), then the result is automatically mapped to a DTO and returned to Controller, that copy what's needed to a ViewModel and returns a View.
The problem here is performance, as I said, the site is planned to have high traffic. In this case, any of the items listed above could reduce performance? Or this combination leaks something more? Should I discard the EF, and use just Dapper? I'm afraid the service layer could reduce the performance because of the traffic.
And finally, I don't know if this architecture is unnecessary, or just poor.
That's a lot of questions, but the focus is to know a great and not "over architected" solution for a medium-sized web site.
Sorry for the English