Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Epoch jobs not executing automatically #101

Open
janober opened this issue Apr 21, 2017 · 6 comments
Open

Epoch jobs not executing automatically #101

janober opened this issue Apr 21, 2017 · 6 comments

Comments

@janober
Copy link

janober commented Apr 21, 2017

Hello,

when I submit a job via SUBMIT_JOB_EPOCH they currently do not get executed automatically at the specified time. They only pick up when another job gets added.
That means if I add a job with current-time + 10 seconds it will not run unless another job gets added in 10 seconds. If not, it keeps on sitting there till one is which could be a few more seconds till hours or days. Is that expected behaviour?

Somehow expected that there is something checking every X seconds to see if there is something that should get executed now.

Thanks!

@p-alik
Copy link
Collaborator

p-alik commented Apr 25, 2017

@janober, have you noticed the note in PROTOCOL

SUBMIT_JOB_EPOCH

    Just like SUBMIT_JOB_BG, but run job at given time instead of
    immediately. This is not currently used and may be removed.

The note was committed 2009 3919ba2 and it looks like there are no tests for SUBMIT_JOB_EPOCH and SUBMIT_JOB_SCHED. I'm afraid both of them are not completely implemented. Unless the author contradict to my assumption, I wouldn't recommend to use them.

@SpamapS
Copy link
Member

SpamapS commented Apr 25, 2017

Eric's not involved with gearmand anymore so don't expect any response from him.

Personally, I go back and forth on whether or not gearmand should implement these commands. On one hand, we have cron and atd that can do this by simply injecting jobs when they're supposed to run. There's also jenkins, buildbot, etc. etc. etc. Time is but one event that likely needs to trigger jobs, and there are many other services that are better at keeping track of the future. I like that gearmand only cares about the present.

But I get that it might be a handy thing to be able to just throw jobs at gearmand and say "do this when the time is X" rather than having to deploy a Jenkins just to schedule stuff.

So, I'd say this is a feature that is missing in gearmand, but what I'd really like to know is whether or not there are users who actually need it.

@esabol
Copy link
Member

esabol commented Apr 25, 2017

I don't have a specific "use case" in mind for this quasi-feature, but it sounds useful to me.

@markomitranic
Copy link

Yes, we absolutely need it.
I do understand however the need for not having this feature, but creating or implementing a new server/container with its own queue, just so i can reschedule failed jobs, seems insane, except if i am instagram or something...

Maybe it could be experimental and activated via a flag or a cron that triggers it.

@SpamapS
Copy link
Member

SpamapS commented Sep 18, 2018

If it were actually implemented, yes it could be experimental. Patches accepted, and especially patches that implement things that were already in the Perl version a million (10+?) years ago.

@esabol
Copy link
Member

esabol commented Aug 31, 2020

There’s a patch (actually multiple patches) for this over on Launchpad:

https://bugs.launchpad.net/bugs/1352411

It seems to have been mixed up with some SSL-related changes though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants