So do you guys think that the ActiveRecord debate is part of the "fat service" vs. "fat object" debate?
One of the selling points of Grails is GORM (Grails Object Relation Mapper): it does a heck of a lot more than add a save() to your domain objects (it adds a bunch of helper methods for finding records, etc.). I'm still wondering where meta-data should go... GORM and Hibernate let you really tweak the heck out of your mappings/objects (things like lazy loading, etc.). Now, you can annotate your domain classes with this info, or use a Hibernate mapping file, neh? The mapping file keeps the ORM specific metadata out of your class itself, which is good for encapsulation, from one vantage point, but it's bad from encapsulation, from another vantage point, as you've got a couple places to change what is essentially related information. Sorta violates the single point of reference deal. Eh. For my money, I'm thinking modeling is really where the beef is at. Well, modeling and model-transformation (modeling ain't much good without transformation). FWIW, I am generally liking the way GORM does constraints and collections and lazy-loading/joins and whatnot. All that info is in your domain object (or can be, I should say-- it's amazingly flexible, considering). But even so, I've moved to using a model to generate the code, vs. just coding it up. God I love generating stuff -- and using a single point of reference to make all these sub-points, vs. managing the sub-points independently? Priceless. So much information is really the same, ya know? It's amazing how just a couple of "weak" model transformations can handle multiple concerns. But, hell, even on the modeling road, you've got to pick how to model what, and how those models interact/overlap/transform. I'm finding that thinking about this stuff is a little easier from a higher level tho, and using code templates to generate the lower-level stuff makes for clean code and consistent structure. Guess it's sorta like the framework argument... Eh. Order and chaos, flip sides of the same damn thing. Go figure. Enough blathering for me tho-- I don't really know what's right or wrong, or even have strong opinions -- but I am having fun. =] -- Seek ye first the good things of the mind, and the rest will either be supplied or its loss will not be felt. Francis Bacon --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CFCDev" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/cfcdev?hl=en -~----------~----~----~----~------~----~------~--~---
