Click here to Skip to main content

Welcome to the Lounge

   

For lazing about and discussing anything in a software developer's life that takes your fancy.
The Lounge is rated PG. If you're about to post something you wouldn't want your kid sister to read then don't post it. No flame wars, no abusive conduct and please don't post ads.

Technical discussions are welcome, but if you need specific help please use the programming forums.


 
GeneralWCMOTD PinpremiumKenneth Haugland16-Jun-14 22:31 
GeneralRe: WCMOTD PinmemberDeathByChocolate16-Jun-14 22:45 
GeneralRe: WCMOTD PinpremiumKenneth Haugland16-Jun-14 22:50 
GeneralRe: WCMOTD [modified] PinpremiumDuncan Edwards Jones16-Jun-14 22:48 
GeneralRe: WCMOTD PinpremiumNagy Vilmos16-Jun-14 22:53 
GeneralRe: WCMOTD PinpremiumKenneth Haugland16-Jun-14 22:54 
GeneralRe: WCMOTD [modified] PinprofessionalArgonia16-Jun-14 22:51 
GeneralRe: WCMOTD PinprofessionalBassam Abdul-Baki17-Jun-14 0:37 
GeneralRe: WCMOTD Pinmember d@nish 17-Jun-14 0:30 
GeneralRe: WCMOTD PinpremiumKenneth Haugland17-Jun-14 0:40 
GeneralRe: WCMOTD Pinmember d@nish 17-Jun-14 0:59 
GeneralRe: WCMOTD PinprofessionalRage17-Jun-14 1:13 
GeneralRe: WCMOTD PinpremiumKenneth Haugland17-Jun-14 1:16 
RantReposted rant about the evil ORM! PinmemberTomaž Štih16-Jun-14 22:26 
Reposted from the Database.
 
At the end of the 90ties we somehow got into ORM. At the time - no matter how hard we tried - we always ended up with a messy and complicated code and filthy compromises. And it hasn't changed. But somehow frameworks like NHibernate and EntityFramework are becoming very popular.

So here is my rant.

Some time ago I worked on large projects and things were pretty predictable. You've got DB model. You generate your SQL procedure layer and your C# layer. Then you create your component / web service / wcf service / restful service and serialize results of your C# calls as POCOs.

Now try to do this with fancy NHibernate objects with auto-resolving proxy objects for related entities. It won't work. Because when objects are serialized their auto-resolving lazy evaluating proxies aren't. To solve it you duplicate /I'll write it again, for drama effect: duplicate/ your objects to create serializable POCOs. And then you create them CRUD functions on top of object models. Or even separate the entities /drama: dereference them having no two entities connected/... And, hey, you are back where you were with the stored procedures - only with lousier performance and three layers of crap on top of it.

So next time someone comes with a fancy-schmancy ORM wrapper it better already include web service / wcf service or restful service abstraction and work on top of it; rather then bellow it! Because otherwise we just off-load drudgery to the web services and call it "business layer" when in fact it is really a freaking "ORM back to stored procedures layer."

There. Hhhh...shhhh... I already feel better.
 
So ... how do YOU handle ORM and web services?
GeneralRe: Reposted rant about the evil ORM! Pinmemberharold aptroot16-Jun-14 22:30 
GeneralRe: Reposted rant about the evil ORM! PinpremiumPIEBALDconsult17-Jun-14 10:40 
GeneralRe: Reposted rant about the evil ORM! Pinpremium_Maxxx_16-Jun-14 23:38 
RantRe: Reposted rant about the evil ORM! PinprofessionalMycroft Holmes17-Jun-14 0:46 
GeneralRe: Reposted rant about the evil ORM! PinpremiumPIEBALDconsult17-Jun-14 10:52 
JokeI walked into a bar the other day and Leslie Nielsen asked me ... PinmemberDeathByChocolate16-Jun-14 22:14 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprofessionalArgonia16-Jun-14 22:22 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinpremiumJohnny J.16-Jun-14 22:26 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprofessionalArgonia16-Jun-14 22:33 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinpremiumJohnny J.16-Jun-14 22:56 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinpremiumPIEBALDconsult17-Jun-14 10:45 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinpremiumJohnny J.17-Jun-14 20:43 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinmemberDeathByChocolate16-Jun-14 22:33 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinpremiumNagy Vilmos16-Jun-14 22:22 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprotectorOriginalGriff16-Jun-14 22:24 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinmemberDeathByChocolate16-Jun-14 22:36 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprotectorOriginalGriff16-Jun-14 22:47 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprotectorOriginalGriff16-Jun-14 22:22 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinmemberDeathByChocolate16-Jun-14 22:41 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprotectorOriginalGriff16-Jun-14 22:48 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinpremiumKenneth Haugland16-Jun-14 23:17 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... Pinpremium_Maxxx_16-Jun-14 23:42 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinpremiumKenneth Haugland16-Jun-14 23:43 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... Pinprofessional_Damian S_17-Jun-14 14:37 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprotectorDaveAuld16-Jun-14 22:36 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinmemberChris Quinn17-Jun-14 0:01 
GeneralRe: I walked into a bar the other day and Leslie Nielsen asked me ... PinprofessionalCorporal Agarn17-Jun-14 1:17 
JokeWhat is the word? PinmemberVivic16-Jun-14 21:34 
GeneralRe: What is the word? PinprofessionalRage16-Jun-14 21:43 
GeneralRe: What is the word? PinpremiumKornfeld Eliyahu Peter16-Jun-14 21:44 
GeneralRe: What is the word? PinprofessionalRage16-Jun-14 21:52 
GeneralRe: What is the word? PinprotectorOriginalGriff16-Jun-14 22:00 
GeneralRe: What is the word? PinprofessionalAgent__00716-Jun-14 22:03 
GeneralRe: What is the word? PinpremiumKenneth Haugland16-Jun-14 22:07 
GeneralRe: What is the word? PinprofessionalRage16-Jun-14 22:14 
GeneralRe: What is the word? PinmemberDeathByChocolate16-Jun-14 22:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web01 | 2.8.140902.1 | Last Updated 3 Sep 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid