[Nitro] Questions to help me evaluate Nitro

Ashley Moran work at ashleymoran.me.uk
Mon Sep 3 06:03:05 EDT 2007

On 3 Sep 2007, at 07:50, Mark Van De Vyver wrote:

> I'm new to OG but I had formed the view that OG tries to make the
> data(base) and the OG model indistiguishable - as much as that can be
> done.  So it seems to me that your db-centric view and OGs' approach
> match?

 From George's response it sounds like Og is pretty flexible with  
regards to migrating the schema.  I'll have to play around with it  
now and see how it works.  I don't think *any* ORM layer perfectly  
maps objects to and from the database, but the code I've seen does  
look pretty smart.

> I'm using OG because my understanding - confirmed in an earlier email
> was that this
> duplication of effort is eliminated if you use OG in its default mode
> (a data mapper).
> If control of the db/table structure is outside of your control
> (fortunately not my situation), or you manually want to make some db
> changes, then it seems you can still use OG as a data wrapper.

When you say data mapper, do you mean in the Martin Fowler sense?   
(<http://www.martinfowler.com/eaaCatalog/dataMapper.html>)  At first  
glance, Og looks like it also follows the Active Record pattern.  The  
automatic schema migrations sound clever, and I don't have any legacy  
schemas to worry about, but I will certainly need the ability to run  
custom SQL.  For example, to create a partial index on a column, or  
update static data.

> Maybe that should be Ruby black magic?  OG implements some neat ideas
> but seems to do it in a very 'Ruby-way'.  Lots of Meta programming
> (all very new to me, but _very_ interesting.)
> Another reason I chose OG is because it seems to be more ruby like.
> This impression I formed from some emails - I've not used Rails/AR so
> I could be off the mark here.

When I said Og black magic, I was thinking more of the automatic  
schema generation.  I'm sure there's plenty of cool metaprogramming  
in there - it wouldn't be Ruby otherwise!  In Rails, there's plenty  
of stuff that looks clever (and IS clever), but makes testing your  
app a real pain.

Anyway George has convinced me that Nitro is worth a look so I will  
start experimenting very soon.


More information about the Nitro-general mailing list