Wow, that's a serious piece of news :) Great ! (John performs little dance).
Most of the pain I had with active-record >= 2.2.x was about queries
outside of the rails http request "cycle". Was fighting hard to get an
open and valid db connection when there was no GET/POST/... involved
:( Hence the ugly singlecon.rb and co.
Please tell me if I could help in any way. Maybe your work will have
an impact on ruote-dm (features suggestions, ...). Just tell me.
BTW, there is a convention you'd perhaps want to follow, it's about
this piece of code :
It 'detects' adjacent engine persistence implementations. For
instance, when the ruote/ dir is next to ruote-dm/, it allows me to
run the functional tests with
ruby19 test/functional/test.rb --dm
I.e. with Ruote::Dm::DmPersistedEngine instead of Ruote::Engine (the
default) or Ruote::FsPersistedEngine (--fs).
In your case, it will expect the adjacent dir ruote-activerecord/ to
contain a *_engine.rb and it will make it available via the
--activerecord switch. It's quite important to test the engine
persistence extensively.
Note that the -C switch disables the expression caching of the engine
persistence. The engine gets a bit slower but always hits the
persistence. This mode is quite important for multi-process installs
(passenger, mongrel packs, ...).
Many thanks !!
Coffee ?
--
John Mettraux - http://jmettraux.wordpress.com
Wow, that's a serious piece of news :) Great ! (John performs little dance).
On Mon, Aug 24, 2009 at 4:49 AM, Kenneth Kalmer<kenneth...@gmail.com> wrote:
> Hi everyone
>
> I took as much time as I could over the weekend to mirror John's ruote-dm
> [1] project in a new ruote-activerecord [2] project. I've promised this to
> John on earlier occasions and last week in #ruote to Dennis. I have to note
> that this is being built and tested against ruote 2.0, and no support for
> the 0.9 series is even considered.
>
> Progress is solid, albeit I haven't pushed to Github yet. The ActiveRecord
> backed expression store and participant are both in and working, I just need
> to support all of John's additional features in ruote-dm. The documentation
> will also take an evening to sort out since it is a deceptively large piece
> of code.
Most of the pain I had with active-record >= 2.2.x was about queries
outside of the rails http request "cycle". Was fighting hard to get an
open and valid db connection when there was no GET/POST/... involved
:( Hence the ugly singlecon.rb and co.
Please tell me if I could help in any way. Maybe your work will have
an impact on ruote-dm (features suggestions, ...). Just tell me.
BTW, there is a convention you'd perhaps want to follow, it's about
this piece of code :
http://github.com/jmettraux/ruote/blob/470594686ee5c4d7110199b86fa9adb6828977c0/test/functional/engine_helper.rb#L96-118
It 'detects' adjacent engine persistence implementations. For
instance, when the ruote/ dir is next to ruote-dm/, it allows me to
run the functional tests with
ruby19 test/functional/test.rb --dm
I.e. with Ruote::Dm::DmPersistedEngine instead of Ruote::Engine (the
default) or Ruote::FsPersistedEngine (--fs).
In your case, it will expect the adjacent dir ruote-activerecord/ to
contain a *_engine.rb and it will make it available via the
--activerecord switch. It's quite important to test the engine
persistence extensively.
Note that the -C switch disables the expression caching of the engine
persistence. The engine gets a bit slower but always hits the
persistence. This mode is quite important for multi-process installs
(passenger, mongrel packs, ...).
Many thanks !!
Coffee ?
Hi Kenneth,
I've just noticed you went on with ruote-activerecord. It's excellent,
keep up the good work ! I'm learning a lot [about ActiveRecord and
Rspec] by reading your code.
There is a small thing that bothers me. What do you think of switching
from "WorkItem" to "Workitem". I use "Workitem" in ruote 2.0 (and
ruote-dm). What about following in ruote-activerecord ?
BTW, I've just pushed a "ticket" branch for ruote-dm. It's the new
name of the 'lock' thing I showed you yesterday. 'ticket' is a better
name, it's not really a lock.
http://github.com/jmettraux/ruote-dm/blob/663de25ee361bb1b632dd3d6c48e2885269a43d4/test/ut_2_ticket.rb
http://github.com/jmettraux/ruote-dm/blob/663de25ee361bb1b632dd3d6c48e2885269a43d4/lib/ruote/dm/ticket.rb
Maybe that could find its way into ruote-activerecord as well. I still
have to adapt the 'concurrence' expression to use it though. Maybe I
could do the "port" by myself with you as the reviewer/committer. I
still have to prove it works for ruote-dm / concurrence, hence the
branch.
And well done with your presentation :
http://www.opensourcery.co.za/2009/08/25/ruote-in-20-minutes-video/ !
Cheers,
Hi Kenneth,
On Mon, Aug 24, 2009 at 4:05 PM, Kenneth Kalmer<kenneth...@gmail.com> wrote:
> On Mon, Aug 24, 2009 at 2:36 AM, John Mettraux <jmet...@openwfe.org>
> wrote:
>>
>> On Mon, Aug 24, 2009 at 4:49 AM, Kenneth Kalmer<kenneth...@gmail.com>
>> wrote:
>> > Hi everyone
>> >
>> > I took as much time as I could over the weekend to mirror John's
>> > ruote-dm
>> > [1] project in a new ruote-activerecord [2] project.
I've just noticed you went on with ruote-activerecord. It's excellent,
keep up the good work ! I'm learning a lot [about ActiveRecord and
Rspec] by reading your code.
There is a small thing that bothers me. What do you think of switching
from "WorkItem" to "Workitem". I use "Workitem" in ruote 2.0 (and
ruote-dm). What about following in ruote-activerecord ?
BTW, I've just pushed a "ticket" branch for ruote-dm. It's the new
name of the 'lock' thing I showed you yesterday. 'ticket' is a better
name, it's not really a lock.
http://github.com/jmettraux/ruote-dm/blob/663de25ee361bb1b632dd3d6c48e2885269a43d4/test/ut_2_ticket.rb
http://github.com/jmettraux/ruote-dm/blob/663de25ee361bb1b632dd3d6c48e2885269a43d4/lib/ruote/dm/ticket.rb
Maybe that could find its way into ruote-activerecord as well. I still
have to adapt the 'concurrence' expression to use it though. Maybe I
could do the "port" by myself with you as the reviewer/committer. I
still have to prove it works for ruote-dm / concurrence, hence the
branch.
And well done with your presentation :
http://www.opensourcery.co.za/2009/08/25/ruote-in-20-minutes-video/ !
Hi Kenneth and all,
It seems that ActiveRecord, when used in a non-rails app, doesn't
manage the db connection pool automatically. (http://
coderrr.wordpress.com/2009/05/05/activerecords-with_connection-is-now-
useful/)
Nando and me did also some tests and wrote about the results in
openwferu user list (http://www.mail-archive.com/openwferu-
us...@googlegroups.com/msg01322.html) Sorry, I could not find the link
to the original post in google groups app. :(
Hope this can help...
Thanks for the headsup on this one, really appreciate it!
Hello Kenneth,
great news. I will work on ruote-dm's history and error tracking as
well. I'd be interested in feedback about history. Maybe I'll include
some stuff to ease process audits and things like that.
Hello,
Kenneth, the author or ruote-activerecord is currently doing an Italy
trip, he'll be back home (ZA) next week.
I'd suggest forking http://github.com/kennethkalmer/ruote-activerecord
and then trying to run the specs against along with the latest ruote
2.0.
ruote-activerecord is aligned on ruote-dm
(http://github.com/jmettraux/ruote-dm), IIRC ruote-ar is quite
complete. The next step for ruote-dm is the implementation of history
storage, this will then have to be ported to ruote-activerecord (if
needed).
Running the specs of ruote-activerecord is important, but there is
another "angle of attack" for testing : running ruote functional test
suite with ruote-activerecord. It's quite easy, from ruote 2.0 (and
assuming that ruote-activerecord/ is at the same level as ruote/
(2.0)), you can do
ruby test/functional/test.rb --activerecord
This will use the activerecord expression storage for all the
functional tests (fingers crossed).
I'll ping Kenneth about you volunteering.
Thanks for the help, cheers,
P.S. what is the thing about sequence { sequence { x } } getting
wobbly on ruote 0.9.x ?