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 6662455
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T02:23:29+00:00 2026-05-26T02:23:29+00:00

Questions 1) When running cron tasks at Heroku, does Heroku have a time limit

  • 0

Questions

1) When running cron tasks at Heroku, does Heroku have a time limit that cron tasks should last only X minutes or can the cron task run for whatever time it needs to complete processing?

2) To optimize my application, I want to move all my processing to batch mode. So I have lots of update queries. Basically that one Heroku cron file is getting messy. What can I do to clean up the code? Should I create multiple rake tasks and invoke the task tasks from the cron file?

2.1) If you agree with that then how do I invoke rake tasks from cron task? Let’s say there are 3 independent rake tasks rake accounts:billing, rake accounts:collections, rake accounts:cleanup. How do I call them in cron file?

  • 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-26T02:23:29+00:00Added an answer on May 26, 2026 at 2:23 am

    There aren’t any time limits that I know of.

    Using multiple tasks instead of one big cron task is a good idea. Not only is it easier to debug and maintain when they’re separate but you can also easily run them individually when needed. And well factored code is a just a good idea all by itself.

    Executing a task from another task is as simple as Rake::Task[task].execute. You’d have something like this:

    desc 'Heroku cron job'
    task :cron => :environment do
        %w{accounts:billing accounts:collections accounts:cleanup}.each do |task|
            Rake::Task[task].execute
        end
    end
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a daily cron job that grabs 10 users at a time and
I'm running a cron job (every 15 minutes) which takes about a minute to
When running a script with cron, any executable called inside must have the full
I am writing a program/script that should check what services are running on a
I have two questions regarding the behavior of running the below code. Why is
A lot of questions have been asked and answered about running server-side javascript on
Not sure if I am doing this right. Reading: http://devcenter.heroku.com/articles/cron#frequently-asked-questions If I have cron
I have seen questions and topics in google referencing running JRE apps in the
I have a php script that does some processing (creates remittance advice PDFs, self-billing
I have a script that I mean to be run from cron that ensures

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.