[Nitro] OG/Ruby/MySQLAdapter create performance
Mark Van De Vyver
mvyver at gmail.com
Thu Aug 30 08:21:13 EDT 2007
Following up on my earlier post (which contained the AR benchmark code
and reference), I've 'converted/ported' the AR benchmark code.
My main purpose was to checkout the different OG ways of creating
records - the times are an interesting bonus.
The previous post:
A couple of points. I'm a Ruby newbie, so there are probably some
clangers in here that make the results meaningless - please let me
know if there is anything that should be changed.
I've only looked at ways that OG provides to create data records.
I'd like to convert this into an './examples/og_create_examples.rb'
and write a spec for each example of these creates - time permitting,
so please post any interesting 'ways to create' (in addition the the
following specific request). I suppose it'd be useful to have a
benchmark/example/spec for each or C.R.U.D.....
In the commented out section you'll see some AR code that creates using SQL.
Can someone provide/point me to how this would be done in OG.
On my machine OG and AR where 'about' the same.
Using the hash initialized model the cleanest/simplest OG create
syntax was the fastest - but this might be improved on?
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 10053 bytes
Desc: not available
Url : http://rubyforge.org/pipermail/nitro-general/attachments/20070830/751f25ab/attachment-0001.bin
More information about the Nitro-general