ruote tmp/log_2012-01-24.html

2012-01-24 08:28:48 utc Skippy1 Quick Q for a Ruote newbie. Once a process has been successfully completed should it's expressions remain in the expression storage?
2012-01-24 08:29:28 utc Skippy1 I've run a few thousand single expression processes and there are now roughly the same number of expressions sitting in the expression storage
2012-01-24 08:29:39 utc Skippy1 (using MongoDbStorage)
2012-01-24 21:11:23 utc jmettraux Skippy1: hello and welcome to #ruote
2012-01-24 21:11:55 utc jmettraux once a workflow has completed, its expressions should not remain in the storage
2012-01-24 21:12:41 utc jmettraux what does your single expression process look like ?
2012-01-24 21:14:02 utc Skippy1 hi
2012-01-24 21:14:19 utc Skippy1 it's just a Ruote.define do
2012-01-24 21:14:26 utc Skippy1 test_participant
2012-01-24 21:14:28 utc Skippy1 end
2012-01-24 21:14:40 utc Skippy1 where test_participant just dumps out some workflow fields to the file
2012-01-24 21:14:55 utc Skippy1 to a file
2012-01-24 21:15:00 utc jmettraux what kind of participant is it ? A block or a class ?
2012-01-24 21:15:05 utc Skippy1 it's a class
2012-01-24 21:15:27 utc jmettraux is there a reply_to_engine(workitem) directive at the end of the consume method ?
2012-01-24 21:16:14 utc Skippy1 yes
2012-01-24 21:16:26 utc jmettraux are there errors in the storage ?
2012-01-24 21:16:51 utc Skippy1 let me just check...
2012-01-24 21:18:00 utc Skippy1 there are quite a few
2012-01-24 21:18:12 utc Skippy1 but I don't recall any errors in any of the tests I ran...
2012-01-24 21:19:33 utc jmettraux it could be that those errors and remaining expressions are from previous, initial tests
2012-01-24 21:20:23 utc jmettraux I tend to clean/purge the storage before each test
2012-01-24 21:21:10 utc Skippy1 it might be
2012-01-24 21:21:14 utc Skippy1 I will try that
2012-01-24 21:22:43 utc Skippy1 i'm using the MongoDbStorage as well
2012-01-24 21:23:44 utc jmettraux this one is a bit tricky, there's ruote-mon around now: which will be the official MongoDB storage
2012-01-24 21:24:19 utc Skippy1 ok I will switch over and test with that as well
2012-01-24 21:24:44 utc jmettraux greatr
2012-01-24 21:24:48 utc jmettraux great
2012-01-24 21:42:35 utc Skippy1 ok I've switched over and run the same process 100 times
2012-01-24 21:42:41 utc Skippy1 it seems to work correctly
2012-01-24 21:42:51 utc Skippy1 but there are 48 errors
2012-01-24 21:42:58 utc Skippy1 and 96 expressions
2012-01-24 21:43:07 utc jmettraux what do the errors say ?
2012-01-24 21:43:34 utc Skippy1 looks like an unitialised Constant somewhere
2012-01-24 21:43:58 utc jmettraux ?
2012-01-24 21:44:45 utc Skippy1 but the participant does some seem to complete as I am getting dumped out files
2012-01-24 21:45:30 utc jmettraux the error details will help us determine what is wrong
2012-01-24 21:47:22 utc Skippy1 well the first expression of my participant is
2012-01-24 21:47:29 utc Skippy1 logger = DaemonKit.logger
2012-01-24 21:47:33 utc Skippy1 just for short cuts
2012-01-24 21:47:51 utc Skippy1 and the error is that DaemonKit is an unknown constant
2012-01-24 21:48:03 utc Skippy1 and yet I am still seeing logging happening using that logger
2012-01-24 21:48:06 utc Skippy1 and files are being dumped
2012-01-24 21:48:13 utc Skippy1 I don't think all are
2012-01-24 21:48:21 utc Skippy1 lemme see how many fail and run the test again
2012-01-24 21:49:08 utc jmettraux reading the stack trace might help
2012-01-24 21:50:03 utc Skippy1 the whole stack trace isn't being displayed in the his Mongo GUI I'm using....
2012-01-24 21:50:09 utc Skippy1 let me run it again
2012-01-24 21:50:17 utc jmettraux ok
2012-01-24 21:50:36 utc Skippy1 ok i've dropped and recreated the mongo db
2012-01-24 21:51:00 utc Skippy1 I'm going to run the same simple process 100 times. each process will write out to a new file
2012-01-24 21:51:04 utc Skippy1 so there should be 100 files
2012-01-24 21:51:37 utc Skippy1 ok only 37 files were written
2012-01-24 21:51:54 utc jmettraux 63 errors then
2012-01-24 21:51:56 utc Skippy1 and there are 63 erros
2012-01-24 21:52:35 utc Skippy1 all the same ... DaemonKit is an unitialised constant
2012-01-24 21:52:48 utc Skippy1 so in some cases the participant is loaded and instantiated correctly?
2012-01-24 21:52:51 utc Skippy1 and in others not so
2012-01-24 21:52:52 utc jmettraux working on Rails ?
2012-01-24 21:52:57 utc Skippy1 no it's in DaemonKit
2012-01-24 21:53:11 utc jmettraux weird
2012-01-24 21:53:43 utc Skippy1 should I put :: in front of DaemonKit.logger to force it to look in the top level name space?
2012-01-24 21:54:14 utc jmettraux if the error message says something like X::DaemonKit is missing then yes
2012-01-24 21:54:43 utc jmettraux if it simply says DaemonKit is missing, then you should probably require DaemonKit before the faulty point is reached
2012-01-24 21:54:52 utc Skippy1 no it's X::DaemonKit
2012-01-24 21:55:05 utc Skippy1 just wierd that sometimes it works and sometimes not
2012-01-24 21:55:59 utc jmettraux autoload issue probably, the DaemonKit author is quite fond of it
2012-01-24 21:57:07 utc Skippy1 I will admonish him at RubyFuZA
2012-01-24 21:57:43 utc Skippy1 (I know Kenneth, worked on a project with him a few years ago)
2012-01-24 21:58:29 utc jmettraux :-) cool !
2012-01-24 21:58:42 utc jmettraux pass my greetings then, when is the FuZa ?
2012-01-24 21:59:34 utc Skippy1 2/3 Feb
2012-01-24 21:59:56 utc Skippy1 I'm using Ruote because of the preso he gave last year...
2012-01-24 22:00:17 utc jmettraux ah sweet
2012-01-24 22:14:58 utc Skippy1 still getting wierd errors... I ran 10 process.. 6 were successful
2012-01-24 22:15:18 utc Skippy1 4 fails with 'udefined method 'debug' for nil::NilClass'
2012-01-24 22:15:34 utc Skippy1 which means that for DaemonKit.logger was nil
2012-01-24 22:15:39 utc jmettraux :-( logger is nil ?
2012-01-24 22:16:43 utc Skippy1 looks like it
2012-01-24 22:16:47 utc Skippy1 no idea why...
2012-01-24 22:16:55 utc Skippy1 or why it works in 6/10 tries
2012-01-24 22:17:51 utc jmettraux In those cases I tend to harden the requires, to make the missing class gets loaded whatever
2012-01-24 22:20:33 utc Skippy1 is this a missing class
2012-01-24 22:20:44 utc Skippy1 it just seems like the logger isn't being initialised...
2012-01-24 22:21:08 utc Skippy1 for some processes....
2012-01-24 22:21:22 utc Skippy1 i don't know if there's a pattern...
2012-01-24 22:21:40 utc jmettraux the code to initialize the logger gets skipped
2012-01-24 22:22:15 utc Skippy1 is it not initialised once when the daemon boots?
2012-01-24 22:22:58 utc jmettraux I have no idea, maybe the participant code is happening before the daemon booting is over
2012-01-24 22:23:34 utc Skippy1 I wait till it's fully booted before firing off processes in a seperate console
2012-01-24 22:23:47 utc jmettraux ah, good idea
2012-01-24 22:38:21 utc Skippy1 I'm busy launching processes one by one in a console
2012-01-24 22:38:30 utc Skippy1 with the worker daemon running in another window
2012-01-24 22:38:43 utc Skippy1 and every 3rd/4th/5th launch an exception will happen
2012-01-24 22:39:12 utc Skippy1 oooooh
2012-01-24 22:39:13 utc Skippy1 wait
2012-01-24 22:39:20 utc Skippy1 I think I'm being stupid
2012-01-24 22:39:46 utc Skippy1 I think in my cutting and pasting I've got a worker running in my console
2012-01-24 22:40:15 utc Skippy1 and in the daemon
2012-01-24 22:40:55 utc Skippy1 so when the console worker picks up the process it doesn't have access to DaemonKit's internals
2012-01-24 22:41:48 utc Skippy1 let me set it up properly....
2012-01-24 22:45:38 utc jmettraux great
2012-01-24 22:48:18 utc Skippy1 ok that worked
2012-01-24 22:49:11 utc Skippy1 just asking for class based participants
2012-01-24 22:49:30 utc Skippy1 is there any way to handle errors/exception in a similar manner to the way delayed_job does
2012-01-24 22:49:40 utc Skippy1 where you can define an error( job, exception ) method
2012-01-24 22:49:47 utc Skippy1 which is called if an error occured
2012-01-24 22:50:02 utc Skippy1 instead of using on_error expressions in the process?