Anyone else regret using Entity Framework?

I have a project that implemented Linq To SQL, and I was very pleased with it. For quite some time, the biggest problem was that the designer was buggy.

Unfortunately, my project now requires multiple table inheritance, and Linq to SQL does not support it. I decided to switch to the Entity Framework when I found out that it supports multiple inheritance and seems to be heading towards Microsoft. But now I'm starting to regret this decision.

For example, by calling Load ()? WTF? If I did not need this data, I would not ask about it! Finding out that all the essential structures of the anal fad become a huge thorn on my side.

In any case ... is there light at the end of the tunnel? When I'm done, will I use EF, or did I make a terrible decision?

Finally, I would like to ask: where was Microsoft with all ORM? Rails ActiveRecord has been working beautifully and simply for many years.

+20
linq-to-sql entity-framework
May 21, '09 at 22:18
source share
6 answers

You are not alone in your pain. There has been a series of ADO.NET blog posts discussing the improvements that are being made to the Entity Framework in .NET 4.0. They seem quite significant, but whether they are sufficient for your needs, only you can judge.

+11
May 21 '09 at 23:40
source share

Good, VS2010 beta is available; can you deploy a virtual machine and see if EF suits you in 4.0?

Personally, I am attached to LINQ-to-SQL at the moment, but probably because I don't need any other functions yet.

+7
May 21 '09 at 23:08
source share

I am really looking forward to using Entity Framework in v4, hopefully Real Soon Now. Of course, in our case, this is accompanied by getting rid of the ORM of the God-fearing home, which is no longer supported, which is worse than the plague - therefore, EF v4 looks like a god-send to me !:-)

Mark

+3
May 23 '09 at 15:41
source share

For one, I was very disappointed with EF v1.0. He promised a lot, but in fact he was extremely restrictive, performed terribly and did not support existing applications and infrastructures.

However, EF v2.0 looks very promising. Microsoft has opened the design process to the masses, allowing those of us who want to see EF to succeed and see if they fit into the wide variety of usage scenarios that our suggestions, tips and opinions really need to offer.

If you are interested in seeing the results of these efforts or want to provide your own input, you should familiarize yourself with the EF design block, here: http://blogs.msdn.com/efdesign/

After all, if Microsoft is still unable to create a flexible ORM that fits into a wide variety of scenarios, there is always NHibernate. I have been using LINQ to SQL, Entity Framework, and NHibernate for some time, and out of the three, NHibernate is the most friendly, flexible, and mature structure. This is not much for visual designers, but if you are disappointed with the limitations, quirks, odd behavior and poor performance of EF, NHibernate is a great alternative.

+3
May 23 '09 at 18:14
source share

I absolutely agree. Lazy loading is what killed the entity structure for me. It simply opens a jar of worms with attachment and detachment of entities to the context instance. I really don't want to worry about these things. But then who did not work with a semi-similar product from Microsoft before :) I am glad that they will fix things in the new version. Until then, the L2S seems to be your best bet.

+3
Jun. 07 '09 at 6:20
source share

To continue:

I am currently abandoning the Entity Framework. The code rewriting was tramatizing, and I'm not quite happy with the result ... significantly due to the lack of lazy loading support.

I decided to return to Linq to SQL and try inheritance on one table at the moment. We do not have many types of children, so for now this should be an ugly but acceptable solution. When the new version of VS and Entity Framework is released, I will consider switching again at this point, because the changes for the new version look promising.

+2
May 26 '09 at
source share



All Articles