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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T00:55:37+00:00 2026-06-16T00:55:37+00:00

After reading all the articles I could not find a solution to my problem.

  • 0

After reading all the articles I could not find a solution to my problem.

  1. I have a java play web-app running good on Heroku. With a web: xxx process in the Procfile
  2. In the same app, I have defined some Jobs.
    • I have MyJob class which extends play.Job
    • I have a Main class while(true) wait and execute MyJob.

my Procfile looks like this.

web:    play run --http.port=$PORT $PLAY_OPTS
worker: java -cp target/classes;target/dependency/* jobs.MyJob

I understand that since this is not a maven project classes and dependency directories dont exists.

But then, how shall I set the worker: java xxxx command?

  • 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-06-16T00:55:39+00:00Added an answer on June 16, 2026 at 12:55 am

    Are you annotating your Job classes? To start a job when Play starts, just do:

    @OnApplicationStart
    public class Bootstrap extends Job {
    

    Or use the @Every or @On annotations:

    @On("0 0 12 * * ?")
    public class Bootstrap extends Job {
    
    @Every("1h")
    public class Bootstrap extends Job {
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

after reading all posts that come close to this, I still find no solution
After reading and finding online, I still do not have any idea how to
after searching up and down, reading all possible articles and tutorials, I grasped the
After a lot of experiments and reading many articles, Q&As, I still didn't find
After reading all sorts of Stackoverflow postings and various documentation including some on http://code.google.com/p/google-api-java-client/
After reading monkeytalk faq from http://www.gorillalogic.com/testing-tools/monkeytalk/documentation/monkeytalk-faq : How does it all work? MonkeyTalk is
After reading MSDN-XAML Namespaces and MSDN-Understanding XAML Namespaces , I still do not understand
After reading quite few articles on deployment, i am bit confused about the procedure.
I was looking at using Amazon's EC2 service after reading this article: http://www.ibm.com/developerworks/java/library/j-javadev2-4/index.html But
I'm about to dive into WF4 and I have been reading blog after article

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.