Thanks Kenneth!
I'll also share my efforts so far. Some background info:
- The code below successfully passes the workitem to the daemon-kit
AMQP agent, but Ruote is having trouble processing the response back
from the agent. More at
http://groups.google.com/group/openwferu-users/browse_thread/thread/fa353d06f3fec736
if you're interested.
- Gem versions:
ruote (2.1.10)
ruote-amqp (2.1.5)
ruote-kit (2.1.7)
daemon-kit (0.1.8pre) - I used daustin's daemon-kit fork (http://
github.com/daustin/daemon-kit)
----------
#!/usr/bin/env ruby
require 'rubygems'
require 'ruote-amqp'
require 'ruote-amqp/participant'
require 'ruote'
require 'ruote/storage/fs_storage'
require 'ruote/storage/hash_storage'
puts AMQP.settings.inspect
engine = Ruote::Engine.new(
Ruote::Worker.new(
Ruote::HashStorage.new()
)
)
listener = RuoteAMQP::WorkitemListener.new(engine)
pdef = Ruote.process_definition :name => 'print_quote' do
sequence do
amqp :queue => 'work1', :command => '/sample/quote'
end
end
engine.register_participant(:amqp, RuoteAMQP::Participant)
fei = engine.launch(pdef)
engine.wait_for(fei)
----------
Hope this is helpful for someone else who is also struggling with
Ruote/AMQP/daemon-kit like I am. :) I would welcome any tips or
pointers you all may have.
On May 2, 2:26 pm, Kenneth Kalmer <
kenneth.kal...@gmail.com> wrote:
> On Sat, May 1, 2010 at 6:53 AM, threetee <
three...@gmail.com> wrote:
> > I've been working on getting ruote and ruote-amqp to use the daemon-
> > kit amqp template as a remote participant. The amqp template refers to
> >
http://gist.github.com/144861for a sample engine, but that example
> > code is pretty outdated and definitely doesn't work with Ruote 2.1.
> > Does anyone know of an updated version of the sample engine that is
> > available for reference, or some other example code for how to
> > integrate modern ruote/ruote-amqp versions with daemon-kit?
>
> > Thanks in advance for any information!
>
> Hi there
>
> Thanks for bringing this under my attention ! I'll clean up the ruote-amqp
> integration in the coming days and update the examples as needed. I'm busy
> setting up a fresh testing environment for my AMQP work so I can fix this as
> well as test the issues you reported on the ruote group.
>
> Best
>
> --
> Kenneth Kalmer
> kenneth.kal...@gmail.comhttp://
opensourcery.co.za