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

Scheduler + CRON #20

Merged
merged 3 commits into from
Apr 30, 2021
Merged

Scheduler + CRON #20

merged 3 commits into from
Apr 30, 2021

Conversation

pkriens
Copy link
Member

@pkriens pkriens commented Apr 29, 2021

The enRoute scheduler had support for CRON. We
adopt this code.

The enRoute scheduler had support for CRON. We
adopt this code.
@stbischof
Copy link
Contributor

stbischof commented Apr 29, 2021

That is great!! Thank you for the fast support!

Maybe this would ve goot to have

https://github.com/aQute-os/biz.aQute.osgi.util/blob/576cb4de913d46e5c72d79b7df31d08c1771f29c/biz.aQute.api/src/main/java/biz/aQute/scheduler/api/annotation/CronExpression.java

SchedulerImpl has us the DefaultZone
Clock clock= Clock.systemDefaultZone();

We may should add an MetaTypeConfig to make the SchedulerImpl configurable.

static final String TIMEZONE_DEFAULT = "default";//or""

@interface SchedulerConfig {
	
	String timeZone() default TIMEZONE_DEFAULT;
}

//constructor

if (TIMEZONE_DEFAULT.equals(schedulerConfig.timeZone())) {
	clock = Clock.systemDefaultZone();
} else {
	clock = Clock.system(ZoneId.of(null));
}

@pkriens
Copy link
Member Author

pkriens commented Apr 30, 2021

Ok, ok. Added this but you can make the test :-)

@pkriens pkriens merged commit 173d814 into master Apr 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants