
Untitled
By: a guest on
Jul 20th, 2012 | syntax:
None | size: 0.70 KB | hits: 15 | expires: Never
Here's the torquebox.yml:
web:
context: /tbmsg
static: public
env: development
tasks:
send_msg:
jobs:
send_msg:
job: SendMsg
cron: '*/5 * * * * ?'
queues:
/queues/msgq:
durable: true
topics:
/topics/msg_topic:
durable: true
Here's the job: send_msg.rb
class SendMsg
def run
#logger.debug "This is a send_msg debug entry"
queue = TorqueBox::Messaging::Queue.new('/queue/msgq')
queue.publish Time.now
end
end
Here's the error:
19:32:20,937 ERROR [org.quartz.core.JobRunShell] Job tbmsg.send_msg threw an unhandled Exception: : org.jruby.exceptions.RaiseException: (NativeException) javax.naming.NameNotFoundException: msgq not bound