Tag Archives: .NET
Entity Framework v4, End to End Application Strategy (Part 2, Data Layer)
In part 1, I talked about what the whole app stack will look like. To recap the stack: SQL Server ↑ Data Layer — EFv4 ↑ (Auto generated AutoMapper configs between entities and DTOs) DTOs (Auto generated with T4 templates, based on the edmx) ↑ Service Layer (WCF REST, based on a template) ↑ (Json.NET [...]
Entity Framework v4, End to End Application Strategy (Part 1, Intro)
Sorry I haven’t posted in so long. Been very busy with new projects at work and a bit of side work. Ok, so I think I am finally moving on from NHibernate, at least for new development. Obviously I’m not going to do anything rash like completely rewrite the data layer of large and complex [...]
The Entity Framework (v1 and v4) Deal Breaker: TPT Inheritance
CodeProject 9/10/2010 Update #3: It appears that MS has deleted the bug on Microsoft Connect. Here is a cached version indexed from Google where you can see it has 34 upvotes, and 22 users saying they can reproduce. I blogged about this in January 2010, and the bug was opened on 3/17/2010. MS didn’t respond [...]
Posted in Code Also tagged C#, entity-framework, inheritance, nhibernate, orm, performance 17 Comments
Eager fetch multiple child collections in 1 round trip with NHibernate
Oren Eini (Ayende), due to some of the comments on his various blog posts regarding EF vs NH that compare some of the different features, has finally put up a post demonstrating how to load a larger object graph in a single trip to the database. So far, all of the examples have been how [...]
More EF4 vs NH Discussion
There’s a post on InfoQ following up the the Entity Framework 4 vs NHibernate (EF4 vs NH) discussion that Ayende started. I posted some of my findings regarding loading of large or complex object graphs in the comments. I have done more research in that vein (it turns out you CAN load a whole object [...]
Making Entity Framework (v1) work, Part 1: DataContext lifetime management
EFv1 is sorely lacking in many areas. That doesn’t seem to stop people from using it, however. If EFv2 weren’t on the way (March 2010), I’d probably still be using NHibernate for everything. However, EFv2 (actually named v4 to “align” it with the .NET version number, or as a marketing ploy to make it seem [...]
TimeSpan or DateTime to Friendly Duration Text (e.g. “3 days ago”)
Data should be displayed to end users in a way that requires the least amount of effort on their part. With dates, do the math for your users ahead of time. Explicit dates may be exact, but relative “duration text” is easier to understand, and it’s usually good enough. Makes users think hard Easy to [...]
Entity Framework v4, End to End Application Strategy (Part 3, Changes to Data Layer)