Hi there,

I am writing a workflow with concurrence participants (or branches). I want 
the concurrence to terminate once one branch returns with a field of a 
specific value (say 'true'). So here is my conceived workflow def:

Ruote.process_definition :name=>"Test", :revision=>"1" do
  sequence do
    set :field=>"my_field", :value=>"false"
    concurrence :over_if=>"${f:my_field}" do
      alpha
      beta
      gamma
    end
    echo "=== my_field: ${f:my_field}"
    zeta
  end
end

When one participant (say beta) is returned with field 'my_field' being set 
to true (as echo showed), I checked the remaining participants in storage, 
and still see alpha and gamma remained uncanceled. I can see that the call 
back 'on_cancel' on storage participant gets called (but an error of 
'method_missing' was thrown, see output below). I don't think it's due to 
this error because if I use :count=>1 to terminate  the concurrence, the 
same error gets thrown but other participants did get canceled. 

We are running ruote 2.2.1 (for some reason we cannot move to 2.3.x yet). 
Has anyone encountered the similar issue? Is it a bug in earlier version(s) 
of ruote? I'd appreciate it if any of you can shed me some light on what is 
going on.

As I said, initially I thought the error had something to do with the 
storage (HashStorage) I used in test, and this is the stack trace when 
canceling participants process gets called:

  ArgumentError
  negative array size (or size too big)
  
.rvm/gems/ruby-1.8.7-p352/gems/rspec-core-2.2.0/lib/rspec/core/extensions/kernel.rb:22:in
 
`(null)'
  
.rvm/gems/ruby-1.8.7-p352/gems/rspec-core-2.2.0/lib/rspec/core/extensions/kernel.rb:22:in
 
`method_missing'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/storage/hash_storage.rb:102:in
 
`delete'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/part/storage_participant.rb:109:in
 
`on_cancel'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:203:in
 
`send'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:203:in
 
`participant_send'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:194:in
 
`each'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:194:in
 
`participant_send'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:134:in
 
`dispatch_cancel'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:46:in
 
`handle'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:292:in
 
`process'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:198:in
 
`step'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:93:in
 
`run'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`run_in_thread'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`initialize'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`new'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`run_in_thread'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/dashboard.rb:87:in
 
`initialize'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/dashboard.rb:87:in
 
`each'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/dashboard.rb:87:in
 
`initialize'

I changed storage by using MongoDbStorage, I still saw similar error when a 
participant was returned:

  ArgumentError
  negative array size (or size too big)
  
.rvm/gems/ruby-1.8.7-p352/gems/rspec-core-2.2.0/lib/rspec/core/extensions/kernel.rb:22:in
 
`(null)'
  
.rvm/gems/ruby-1.8.7-p352/gems/rspec-core-2.2.0/lib/rspec/core/extensions/kernel.rb:22:in
 
`method_missing'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-mongodb-f583d47f0e96/lib/ruote-mongodb/mongodb_storage.rb:99:in
 
`delete'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/part/storage_participant.rb:109:in
 
`on_cancel'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:203:in
 
`send'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:203:in
 
`participant_send'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:194:in
 
`each'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:194:in
 
`participant_send'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:134:in
 
`dispatch_cancel'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/svc/dispatch_pool.rb:46:in
 
`handle'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:292:in
 
`process'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:198:in
 
`step'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:93:in
 
`run'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`run_in_thread'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`initialize'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`new'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/worker.rb:104:in
 
`run_in_thread'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/dashboard.rb:87:in
 
`initialize'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/dashboard.rb:87:in
 
`each'
  
.rvm/gems/ruby-1.8.7-p352/bundler/gems/ruote-b66b34f1315c/lib/ruote/dashboard.rb:87:in
 
`initialize'

-- 
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

Reply via email to