On Fri, Apr 20, 2012 at 01:11:39AM -0700, Claudio wrote:
>
> With my team, I am using the wonderful Ruote engine (recently upgraded
> to 2.3.0) in a production environment, with an average of 20 new
> processes created every day.
>
> I recently fixed a bug in a workflow that caused some workitems to
> move into an error condition.
>
> I had the following information about the error:
> message:
>   #<NoMethodError: undefined method `size' for nil:NilClass>
> trace:
>   /home/rails/apps/arts/shared/bundle/ruby/1.8/gems/ruote-2.2.0/lib/
> ruote/exp/fe_concurrence.rb:286:in `merge_all_workitems'
>   .../ruby/1.8/gems/ruote-2.2.0/lib/ruote/exp/fe_concurrence.rb:258:in
> `reply_to_parent'
>   .../ruby/1.8/gems/ruote-2.2.0/lib/ruote/exp/flowexpression.rb:228:in
> `do_apply'
>   .../ruby/1.8/gems/ruote-2.2.0/lib/ruote/worker.rb:326:in `launch'
>
> The mistake was the use of a :unless clause in a :concurrence
> expression, as highlighted by the following unit test:
> https://gist.github.com/beaefdcc70a718c42ed5
>
> Nesting the :concurrence expression into a :sequence expression and
> moving the :unless clause up into the :sequence resolved the problem
> (but there were other ways, such as an :if expression).
> Probably the issue is documented, but I could not find it.

Hello Claudio,

excellent! I will dig into this issue report. Thanks a lot!


> However, my current problem is with the errors that such situation
> raised.
> From my business point of view, I resolved with restarting a new
> process for any process in error state.
> Therefore the processes in error state had to be removed from the
> engine.
>
> I tried to kill those processes with
>   @engine.kill_process(error.wfid)
> but that seems to have no effect.
>
> Am i making any mistake?

No you're doing it right. There is probably something going bad during
the kill operations.


> Can someone suggest me a way to remove definitely the processes?

You could remove all the expressions, schedules and trackers from the storage,
that would effectively vaporize the process instance.

I guess you're using ruote-couch. It would mean removing all the documents
that have a "wfid" => your_wfid or a "fei" => { "wfid" => your_wfid } at
their top level (proceed with caution).

Tell me if you need help with that.

I can probably write a "vaporize" method that works with any storage, tell me
if you're interested. I should write it anyway, it seems a very necessary
tool.


Cheers,

John

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