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

Add RecurrenceRule-Trigger #1276

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

tommasopeduzzi
Copy link

This has been discussed in this issue: #1259
This is still very much a WIP and I am happy to make any changes.
List of changes:

  • Added the Recurrence-class with all it's dependencies to Impl/PDI
  • Added RecurrenceRuleTrigger Interface as well as Implementation as a sort of interface between the scheduler and the Recurrence class
  • Added RecurrenceScheduleBuilder for easy creation of the trigger
  • Added tests testing the RecurrenceScheduleBuilder.

@lahma
Copy link
Member

lahma commented Mar 20, 2022

@tommasopeduzzi sorry it's been such a long time that it has taken me to address this.

I had some concerns like hiding the implementation as internal (anything from the 3rd party library), which I tried to push to your branch, but as you've made the PR from main - I cannot do that. Ideally a PR would come from a separate branch to keep main "clean".

Second things I noticed that the PDI library expect local times and Quartz always uses UTC times as base. I'm not sure if the conversions are handled properly - the trigger doesn't have concept of current time zone like cron trigger does. What are your thoughts?

@tommasopeduzzi
Copy link
Author

Hello @lahma! No problem!

You're right about the git mess, I am going to make a new branch and cherrypick them over. Is that a valid solution to the problem?

I could probably change the Recurrence-Class in such a way, that it converts all the local times to UTC Time on assignment, that shouldn't be too hard and would be an easy fix to the problem...

Writing a new Recurrence class would also be an option and shouldn't be too hard, based on the specifications. Is that a better solution?

@lahma
Copy link
Member

lahma commented Mar 20, 2022

I'm quite fine with any solution you find plausible for you to work with. Using the current libraries is fine, but just the concern about how "local time" behaves if it cannot be defined (parametrizable time zone). Generally triggers and time zones can get a bit tricky, so bugs might be ahead, but it's understandable for a new feature not to be 100% bullet proof in v1.

@sonarcloud
Copy link

sonarcloud bot commented Jul 18, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

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