On Wed, Aug 03, 2011 at 08:28:22AM -0700, Akeem A. wrote: > > If it isn't too much trouble, I am still having a bit of an issue > with the history service using head of the master branch. When looking > at the object type of context.history after adding the service it is > StorageHistory as to be expected, but history isn't recorded as > expected. Modifying Ruote::Context.default_conf to include > StorageHistory does function properly as stated by Eric, would you be > able to point me in a direction of other object that used in the > process of recording process history?
Hello Akeem, I have added a test to verify that if newly registered history gets the messages, and it does: https://github.com/jmettraux/ruote/commit/e68f127b6b768ff8fee8218bed099e8591b8ed6f The default_conf modification you're doing is quite hardcore. You could re-open the Ruote::Context class to modify #default_conf instead of forking ruote, but it could be considered as bad as the previous solution. The right way to modify the service list is to do something like ---8<--- opts = { 'history' => [ 'ruote/log/storage_history', 'Ruote::StorageHistory' ] } engine = Ruote::Engine.new( Ruote::Worker.new( Ruote::CompositeStorage.new( Ruote::FsStorage.new('ruote_work', opts), 'msgs' => Ruote::HashStorage.new(opts)))) --->8--- I suspect the #add_service doesn't work for you because your worker is not in the same Ruby runtime as the one were you run it (the #add_service). Hence the "passing the history to use at start time is important. The upcoming ruote 2.2.1 has a new configuration switch keyed "preserve_configuration", it's useful to set the configuration once and then, with 'preserve_configuration' => true, make sure it's not overriden. Sorry if this sounds confusing, don't hesitate to ask further questions if necessary. Thanks for you help, -- John Mettraux - http://lambda.io/processi -- you received this message because you are subscribed to the "ruote users" group. to post : send email to [email protected] to unsubscribe : send email to [email protected] more options : http://groups.google.com/group/openwferu-users?hl=en
