Is a common database interface or a feature specific (services) db interface design is a good approach when we use ORM?
I'm designing application with three-tier model (UI-server-DB) application, includes 8 to 10 major features with the following model: - The database and business logic is in .net server application and UI is another WPF application - Each feature in the server app exposes individual service interface (WCF) for the UI
Basically I'm looking for design ideas and inputs for interfacing to the database in the server application using ORM library from LLBLGen Pro.
Approach 1:
- Create a common database class library in the server application which includes the all the entity classes and datamapping classes. Individual features will reference this common class library
Approach 2:
- Create db class library for each of the feature service ( 8 to 9 services) and entity classes and datamapping classes will be in this library. So individual feature is more modular and less depends on other features in the application.
So looking for the modularity, scalability and maintainability of the application, what would be a good design approa开发者_如何学JAVAch??
-Hari
I would use a single WCF Data Service and for each feature I would create a diferent EndPoint.
精彩评论