-
Notifications
You must be signed in to change notification settings - Fork 382
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
Additional docs for runoncreate option #946
Comments
It does replicate this behavior. I agree that it is reasonable to expect a job to only be triggered by the API. I am reluctant to make this the default behavior, because people may depend on it. But what about a second request parameter, like |
Ah I see now that the current approach makes sense as the default behavior. I gave it a try and see what you mean, run job does indeed wait. I just had the wrong assumption going in.
|
PR #950 should clarify the run behavior. |
Is your feature request related to a problem? Please describe.
Jobs created with
runoncreate
seem to both create and execute the job as part of the request and do not return a response until the job execution has completed. Jobs created withoutrunoncreate
respond immediately after the job has been created.Describe the solution you'd like
Docs should be clear about the execution difference between
runoncreate
and normal jobs (runoncreate
= blocking job execution (job creation + job execution) VS. norunoncreate
= "asynchronous" job execution (job creation only, execution happens later)). ORrunoncreate
should operate asynchronously and return once the job has been created and execute the job in the background, just like adding a scheduled job.Describe alternatives you've considered
Seems like adding a job and executing immediately without the REST request hanging while the job executes can be done by creating the job as disabled and enabling/running it after creation, however this requires multiple requests, and my initial assumption was that
runoncreate
would replicate this behavior. I have used other schedulers that treat a "run immediately" job exactly the same as a scheduled job which is where my confusion came from.Appreciate the project! I just had the wrong assumption that
runoncreate
jobs would return the job object and execute the job in the background rather than blocking until execution completed. Took me a while to figure this out so hope it helps someone.The text was updated successfully, but these errors were encountered: