Displaying 1 result from an estimated 1 matches for "newsletter_worker".
2007 Oct 31
4
How you want BackgrounDrb to behave
...om you
guys. So, please reply back.
The code has changed significantly and its no longer using DRB. But I
will keep the name BackgroundRb. Ok, in new API, a worker looks like
this:
require "net/smtp"
require "guid"
class NewsletterWorker < Packet::Worker
set_worker_name :newsletter_worker
def worker_init
puts "starting the worker"
end
def receive_data p_data
end
# this is where a request from rails will be received. so implement
this method
# if you want to trigger your workers from rails.
def receive_internal_data p_data
self.send(p_data[:method],p...