Can Anyone recommend a well design open source project with Entity Framework? [closed]
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this questionCan Anyone recommend a well design open source project with 开发者_如何学JAVAEntity Framework? I had some tastes about the Entity Framework 4, but I would love to know how people use this framework in some large projects.
Many thanks.
Daoming
While not large, you could check out the All-In-One Code Framework samples. I think there are at least a few examples of the Entity Framework in there. One specific example is:
How to work with table relationships and entity inheritances in ADO.NET Entity Data Model
This code sample includes a step-by-step guide about how to work with Entity Data Model in various ways, including One-to-Many association, Many-to-Many association, One-to-One association, table merging, table splitting, Table-per-Hierarchy inheritance, and Table-per-Type inheritance.
EDIT:
They just added another sample:
CSEFCodeOnly, VBEFCodeOnly
These two samples illustrate how to use one of the EF4 new features, Code Only, to create the EDM metadata and the corresponding .edmx file with POCO entity classes during runtime. They also demonstrate some basic insert and query operations to test the EDM metadata generated by Code Only.
So far the best I've found is http://www.nopcommerce.com/ - since 1.70 (July 7, 2010) they have been using Entity framework.
See http://kigg.codeplex.com/ Highly recommended for an ALT.NET style of doing Entity Framework.
It shows a way of abstracting yourself from the ORM even.
A different project with similar architecture: http://shrinkr.codeplex.com/
Checkout the product called Virto Commerce. The site is http://virtocommerce.com. It is an open source project based on Entity Framework using Repository and Unit Of Work pattern. The source code is https://github.com/VirtoCommerce/vc-community.
It's 2014. The answer to the question is still no.
The reason is not obvious, I hope I can explain. Most typical open source project become successful because they are extensible, and thus allow the community around it to grow. Extensible means extending Entities and thus the database in some way for each plugin. However, EF only supports one version of an entity graph, and so you can't say, add a plugin, and then upgrade the original database. It'll break migration. And thus people don't use EF in OS projects.
You can see people are struggling to create plugins in nopcommerce because of this. Any plugin that needs additional properties on an object requires code changes in the core. Essentially, any deployment of nopcommerce that has a plugin, is a fork of the project. The end user ends up becoming the developer because they now have to do source code control, merges, etc. A person selling things online doesn't have that kind of skill. They just want to install plugin, and go. So... no, EF is terrible for open source projects. For big monolithic projects, it's great though.
精彩评论