Adam, I presume you have run the migration that is generated by delayed_job. You also have the initializer file.
Earlier would you start the long running as Download.new.start ? If so, Download.new.send_later(:start) would definitely work. If 'start' is an instance method in the Download model, it will work. If 'start' is a class method, you cannot (obviously) do a Download.new.start -- then you can enqueue the task. Send some more details - and I can help you sort this out. - Gautam @gautamrege On Wed, Nov 10, 2010 at 11:07 PM, Adam <[email protected]> wrote: > I'm currently trying to set up the delayed job solution, running into > some problems > but if I get it to work I think it will do the job, the importing will > be done about once a day. > > Since I'm on the topic I've tried to do the railscast setup from > delayed job but both of the versions showed there dont do it for me > the first one with the send_later method > Download.new.send_later(:start), shows "undefined method `perform' for > #<YAML::Object: ..." > I load the config in environment.rb file (raw_config = > File.read(RAILS_ROOT + "/config/config.yml") > APP_CONFIG = YAML.load(raw_config)[RAILS_ENV]) > > the second option using a new class after jobs:work > > "Job failed to load: Unknown handler. Try to manually require the > appropriate file." > > > On 10 Lis, 17:06, Gautam Rege <[email protected]> wrote: > > I do agree - infact my preferred setup us Nginx+Passenger. > > > > However, given that the current problem on hand is one long running > > task slowing things down and not a scale issue (I.e number of > > requests), delayed_job may just do the trick. > > > > My 2 cents :) > > - Gautam > > Sent from my iPhone > > > > www.joshsoftware.com > > > > On Nov 10, 2010, at 8:50 PM, Frederick Cheung < > [email protected] > > > > > > > > > > > > > > > > > wrote: > > > > > On Nov 10, 12:55 pm, Adam <[email protected]> wrote: > > >> this sound very interesting I'll check that out > > > > > While delayed_job is handy, you will eventually run out of steam if > > > you only have one mongrel. Others have suggested mongrel_cluster for > > > running multiple mongrels, you might also want to consider passenger, > > > which will fork extra rails instances as needed. > > > > > Fred > > > > > -- > > > You received this message because you are subscribed to the Google > > > Groups "Ruby on Rails: Talk" group. > > > To post to this group, send email to rubyonrails- > > > [email protected]. > > > To unsubscribe from this group, send email to > [email protected]<rubyonrails-talk%[email protected]> > > > . > > > For more options, visit this group athttp:// > groups.google.com/group/rubyonrails-talk?hl=en > > > . > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<rubyonrails-talk%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/rubyonrails-talk?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

