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

Create new Manual trigger annotation #7

Open
timmolter opened this issue Jun 10, 2016 · 7 comments
Open

Create new Manual trigger annotation #7

timmolter opened this issue Jun 10, 2016 · 7 comments

Comments

@timmolter
Copy link
Member

So that the scheduler loads it on startup, but it's just a manually triggered job. Eliminates need for jobs.xml in some cases.

@Gaudon
Copy link

Gaudon commented Jan 17, 2018

Was this ever added? I presume to have a job ready to fire but be triggered externally by another web service for example.

@timmolter
Copy link
Member Author

Not yet, sorry. You could try programmatically creating a SimpleTrigger with repeat set to -1, which will fire only once.

@Gaudon
Copy link

Gaudon commented Jan 18, 2018

Yeah it would be a very useful feature to have.. in the case of scaling infrastructures I would like to avoid having 'n' number of instances running the same jobs in parallel / at all. Instead, I'd like to have an external trigger hit the web api to launch the job on a single instance that may be passed the request through something like a router / load balancer.

@timmolter
Copy link
Member Author

In case you didn't see it and it's useful, if you set concurrency = false, then only one instance of the job will run.

@Gaudon
Copy link

Gaudon commented Jan 18, 2018

I did see that setting, but in this case the same source / compiled code is deployed on additional scaling instances without any knowledge of one another (from the code's perspective). Considering this, I don't believe the concurrency feature is applicable to my use case.

I'm thinking of the case where a front end load balancer is serving X number of servers, all running the same code, which all contain the same sundial jobs. Externally a job request comes in (with a token) through the load balancer and is handed off to any single instance (usually the one with the least load) with instructions / credentials to execute a given job (such as a maintenance routine) on a common database between all instances.

@timmolter
Copy link
Member Author

you could try quartz, as it's been designed to run across multiple machines. the job statuses are coordinated via a central DB.

@Gaudon
Copy link

Gaudon commented Jan 19, 2018

I've heard of Quartz, but Sundial just seemed "better" hah. But with that being said I'll look into it and see if it fits my use case any better.

Cheers.

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

2 participants