Hi,
I have inherited a rails 2.0.2 app which I'm eventually going to rebuild as rails 3.2.x or whatever. The server it's running on is pretty old, too, and features a deprecated kernel. So, I transferred the app to a new vps while I set up a new app using rvm and all that.
Everything is working as expected except for order processing. Orders are created, but emailing is failing. This piece is supposedly handled by bj, and it should 'just work.' No daemon running. Has anyone used bj recently? Here's the code in app/model/order.rb - lines 13 and 14 make the calls to Bj.
And there is nothing exceptional in the logs, which I've set to debug. You can see the item added to the bj_job table:
Bj::Table::Job Create (0.000398) INSERT INTO `bj_job` (`runner`, `started_at`, `is_restartable`, `submitted_at`, `submitter`, `tag`, `state`, `stderr`, `stdin`, `env`, `stdout`, `priority`, `finished_at`, `exit_status`, `command`, `pid`) VALUES(NULL, NULL, 1, '2012-05-10 16:17:44', '
elegantfoods.net', '', 'pending', NULL, NULL, NULL, NULL, 0, NULL, NULL, './script/runner app/jobs/order_notification.rb 21909', NULL)
And it makes it in to the database
mysql> select * from bj_job where bj_job_id = 63879 \G
*************************** 1. row ***************************
bj_job_id: 63879
command: ./script/runner app/jobs/order_notification.rb 21909
state: pending
priority: 0
tag:
is_restartable: 1
runner: NULL
pid: NULL
submitted_at: 2012-05-10 16:26:25
started_at: NULL
finished_at: NULL
env: NULL
stdin: NULL
stdout: NULL
stderr: NULL
exit_status: NULL
1 row in set (0.00 sec)
But it doesn't trigger anything to 1. send along an email and 2. flip the bj_job.state to 'finished.'
Has anyone else set up Bj?
Thanks,
Steve