We are developing the application with MVC and Repository Pattern. Currently we are using EF as an ORM. But Later we need to change the ORM to nHibernate. Any Idea on the architecture.Currently I plan the architecture as Contracts:Model/Entities/Repository-Interface/Service-Interface DataLayer(Reference Contracts)Repository ImplementationService Layer(Reference contracts, DataLayer)Service ImplementationWeb (Reference Contracts,ServiceLayer)Implement Dependency injection (Unity)Here the DataLayer is tightly coupled. So I need to break and make like thisContracts:Model/Repository-Interface/Service-Interface DataLayer(Reference Contracts)Entities/Repository Implementation (which will return Models)Service Layer(Reference contracts, DataLayer)Service ImplementationWeb (Reference Contracts,ServiceLayer)Implement Dependency injection (Unity)Whether above will work if we change the ORM, or it will have major impact.
Repository Pattern with Multiple ORM
design;design patterns;object oriented design;mvc;orm