Example of ServiceStack REST services integrated with ASP.Net MVC 4
This pretend to be a good example of how to integrate ServiceStack REST services within an ASP.NET MVC4 application which consumes those REST services.
It consists on the following layers/projects
- Data layer which interact directly with the database tables
- It uses Entity Framework to map tables and provide querying functionality. It may not be the best apprach in terms of performance but it is easy to implement right now, and it's acceptable since it is not the final goal of this example.
- Exposes functions in a IxxxxData interface which will be implemented on classes that interact with Entity Framework.
Api/Dto - Data Transfer Objects with requests and responses for REST services
Api/Services - Service Stack services using Api/Dto and Api/DataLayer
WebApp/Mvc - ASP.NET MVC4 application that consumes Api/Services REST Services to GET, POST, PUT and DELETE records.