Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3315700
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T22:22:51+00:00 2026-05-17T22:22:51+00:00

For http://github.com/collectiveidea/delayed_job Let’s say I just start a brand new Rails project and want

  • 0

For http://github.com/collectiveidea/delayed_job

Let’s say I just start a brand new Rails project and want the following to be run every 1 minute:

puts "Time is now #{Time.now}"

How would I add it to the project?

The README says:

class NewsletterJob < Struct.new(:text, :emails)
  def perform
    emails.each { |e| NewsletterMailer.deliver_text_to_email(text, e) }
  end    
end  

Delayed::Job.enqueue NewsletterJob.new('lorem ipsum...', Customers.find(:all).collect(&:email))

but where should you put this content? Do you run it once to enqueue? How do you set the start time and the frequency?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T22:22:52+00:00Added an answer on May 17, 2026 at 10:22 pm

    delayed_job is gem for background tasks. You need a scheduling tool for that. I recommend http://github.com/javan/whenever.

    http://www.ruby-toolbox.com/categories/scheduling.html

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying delayed_job now, and have some questions. From the http://github.com/collectiveidea/delayed_job page, I can
Does rails do any validation for datetime? I found a plugin http://github.com/adzap/validates_timeliness/tree/master , but
http://github.com/collectiveidea/awesome_nested_set awesome nested set plugin and currently, if I choose a sub category as
I am using this http://github.com/professionalnerd/simple-private-messages plugin in rails and I am on a user
I am using Kal calendar from http://github.com/klazuka/Kal . I want to use this calendar
I've got a repository on GitHub ( http://github.com/hrickards/PHP-Crypto ) for a little project me
I'm trying to upload my FAKE project ( http://github.com/forki/FAKE ) to RubyGems from F#:
There exists the multisite plugin ( http://github.com/dasil003/rails-multisite/tree/master ) that allows for multiple view folders
I installed the exception notification plugin from http://github.com/rails/exception_notification/tree/master I can confirm that my ActionMailer
Hi I downloaded the plugin from http://github.com/techweenie/restful-authentication.git Then I run rails generate plugin authenticated

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.