Add exclude_hours and valid_hours attributes to cycledef#123
Open
guoqing-noaa wants to merge 1 commit intochristopherwharrop:developfrom
Open
Add exclude_hours and valid_hours attributes to cycledef#123guoqing-noaa wants to merge 1 commit intochristopherwharrop:developfrom
guoqing-noaa wants to merge 1 commit intochristopherwharrop:developfrom
Conversation
- exclude_hours: removes specified hours from expanded cycles - valid_hours: keeps only specified hours in expanded cycles - Updated CycleInterval class with hour filtering in next/previous/member? - Updated XML schemas and workflowdoc.rb parser - Added unit tests for new functionality - raise ERROR if exclude_hours/valid_hours in cron-style <cycledef> Example usage: <cycledef exclude_hours="3 4 5 6">201101010000 201112311800 06:00:00</cycledef> <cycledef valid_hours="0 6 12 18">201101010000 201112312300 01:00:00</cycledef>
Author
|
@christopherwharrop-noaa I closed PR #122 and create a new one here. Let's use this PR. Thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add exclude_hours and valid_hours attributes to cycledef
<cycledef>Example usage:
solved problem:
This PR address the complexity in the specification of the following types of cycles:
For example, during the retro period
2024122712-2025021012, we need to run a task only at03-08and15-20cycles each day. Currently, we need to use 5 differentcycledefto correctly represent this situation:With this PR we can simplify the above 5
cycledefinto one:This significantly simplifies our workflow logic.