# File lib/ruote/exp/flowexpression.rb, line 166 def self.do_action (context, msg) fei = msg['fei'] action = msg['action'] if action == 'reply' && fei['engine_id'] != context.engine_id # # the reply has to go to another engine, let's locate the # 'engine participant' and give it the workitem/reply # # see ft_37 for a test/example engine_participant = context.plist.lookup(fei['engine_id'], msg['workitem']) raise( "no EngineParticipant found under name '#{fei['engine_id']}'" ) unless engine_participant engine_participant.reply(fei, msg['workitem']) return end # normal case fexp = nil 3.times do fexp = fetch(context, msg['fei']) break if fexp sleep 0.028 end # this retry system is only useful with ruote-couch fexp.send("do_#{action}", msg) if fexp end