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

Native support for CronJob: convert cron endpoints to fire once at startup #222

Closed
nicolaferraro opened this issue Jan 8, 2020 · 3 comments · Fixed by #223
Closed

Native support for CronJob: convert cron endpoints to fire once at startup #222

nicolaferraro opened this issue Jan 8, 2020 · 3 comments · Fixed by #223

Comments

@nicolaferraro
Copy link
Member

Related to apache/camel-k#1182

We should implement via a pluggable runtime module a customizer/loader that, when activated, makes sure an integration fires a single execution of every timer or quartz consumers at startup and immediately shutdown everything after the exchange is processed.

@lburgazzoli
Copy link
Contributor

We should probably introduce a concept of source customizer/trait so we can apply multiple traits to ta source in a consistent way

@davsclaus
Copy link
Contributor

Just mind if the user has both a timer/quartz route and a non cron like route in the same integration? I guess we need to check that this is the only route.

Also you can set camel main, the max number of messages to process (eg set it to 1 to have camel main terminate after that 1 message).

@lburgazzoli
Copy link
Contributor

lburgazzoli commented Jan 9, 2020

Yes we do something similar for the knative-source where we fail if there is more than one route. Unfortunately the camel-main do not yet support exit the application in camel-quarkus (we dependson quarkus command mode to be implemented for that but it is not yet ready)

nicolaferraro added a commit to nicolaferraro/camel-k-runtime that referenced this issue Jan 9, 2020
nicolaferraro added a commit to nicolaferraro/camel-k-runtime that referenced this issue Jan 9, 2020
nicolaferraro added a commit to nicolaferraro/camel-k-runtime that referenced this issue Jan 13, 2020
nicolaferraro added a commit that referenced this issue Jan 13, 2020
Fix #222: initial implementation of native cron support
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 a pull request may close this issue.

3 participants