Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
1) https://habrahabr.ru/company/microsoft/blog/101121/
Well, i.e. It seems clear what to use in new projects.
2) use the repository: codereview.stackexchange.com/questions/57401/repos... , but I ask you, do not make methods that accept Expression and return IQueryable - such a "repository" is completely unnecessary and does not abstract anything, but only harms . Make methods for each specific query type that accept specific search constraints and return an IEnumerable. It is realistic to test such methods, and you will not get a leaky abstraction that will suddenly give you errors at runtime for non-standard entity fetch requests. And most importantly - you will not depend on a specific ORM.
3) do not forget that ADO.NET and other ORMs have not gone anywhere, thick ones like NHibernate, and not so much. If you make two insert requests to the database in your application (some kind of telemetry service), there is no need to fence the garden with ORM. Or if you have an old-school database with a large number of stored procedures on the server, then a thick ORM is also useless (some kind of billing, for example).
If I remember anything else, I'll write.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question