Comments (2)
Thanks. I had the mechanism explained in the README, and I added it to the stopJob
methods. I agree that an interrupt mechanism would be nice to have as well. I'll leave this issue open as a feature request.
from sundial.
I just looked into this and there's really now way to do it. Each Job runs in its own thread and I can call interrupt on the thread but I cannot then use that event to interrupt a wait or sleep or infinite loop in the Job itself. That's what the checkTerminated();
mechanism is for, which is essentially the same thing you'd have to do in the case if Jobs were Runnables directly, which would need some kind of poison flag as demonstrated here: https://stackoverflow.com/a/13476257/1625820
For an example see SampleJob9.java
. In a loop within the Job you should just add a call to checkTerminated();
.
from sundial.
Related Issues (20)
- Nice to have option to add triggers with priority
- Create an object and then give it to Sundial to run. HOT 3
- Support for custom implementation of JobFactory HOT 2
- OutOfMemoryError HOT 1
- How to reload Jobs.xml ina a web app? HOT 2
- Please package as 'bundle' for use in OSGi environment HOT 2
- Create new release to include enhanced error logging HOT 3
- Start job by name HOT 1
- Annotated job not loaded from main/java/resources package... HOT 1
- Jobs.xml not parsing HOT 4
- Commented out annotation is still found HOT 2
- package annotated jobs does not work with tomcat war versioning HOT 7
- ExecutorService as thread pool HOT 2
- JobListener Support in Sundial HOT 1
- Run a single job explicitly / stay alive until finished HOT 6
- schedule admin ui HOT 1
- Ineffective JobInterruptException
- Configure DB backed JobStore? HOT 1
- Scheduler cannot load all annotated job classes from multiple locations HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sundial.