Validate interval when a task is updated#222486
Merged
ersin-erdal merged 9 commits intoelastic:mainfrom Jun 20, 2025
Merged
Conversation
Contributor
|
Pinging @elastic/response-ops (Team:ResponseOps) |
Contributor
💚 Build Succeeded
Metrics [docs]History
|
doakalexi
approved these changes
Jun 20, 2025
Contributor
doakalexi
left a comment
There was a problem hiding this comment.
LGTM! I tested locally and works as described
Contributor
|
Starting backport for target branches: 8.19 https://github.com/elastic/kibana/actions/runs/15781523545 |
kibanamachine
pushed a commit
to kibanamachine/kibana
that referenced
this pull request
Jun 20, 2025
Resolves: elastic#213391 This PR adds validation for task interval where it is updated. There are 5 places in the TaskStore that we update the interval: `schedule`, `bulkSchedule`, `update`, `bulkUpdate` and `bulkPartialUpdate` For the bulk operations we just skip the task with invalid interval, for schedule and update throw an error and stop the execution. ## To verify: Create a rule with connector. Let it run for a while. Then update the rule. There shouldn't be any error. (cherry picked from commit 723fcc3)
Contributor
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
kibanamachine
added a commit
that referenced
this pull request
Jun 22, 2025
# Backport This will backport the following commits from `main` to `8.19`: - [Validate interval when a task is updated (#222486)](#222486) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Ersin Erdal","email":"92688503+ersin-erdal@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-06-20T14:45:08Z","message":"Validate interval when a task is updated (#222486)\n\nResolves: #213391\n\nThis PR adds validation for task interval where it is updated.\n\nThere are 5 places in the TaskStore that we update the interval:\n`schedule`, `bulkSchedule`, `update`, `bulkUpdate` and\n`bulkPartialUpdate`\n\nFor the bulk operations we just skip the task with invalid interval, for\nschedule and update throw an error and stop the execution.\n\n## To verify:\nCreate a rule with connector.\nLet it run for a while.\nThen update the rule.\n\nThere shouldn't be any error.","sha":"723fcc335210fa68c37e7db63c35c1530ec5f1d7","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:ResponseOps","backport:version","v9.1.0","v8.19.0"],"title":"Validate interval when a task is updated","number":222486,"url":"https://github.com/elastic/kibana/pull/222486","mergeCommit":{"message":"Validate interval when a task is updated (#222486)\n\nResolves: #213391\n\nThis PR adds validation for task interval where it is updated.\n\nThere are 5 places in the TaskStore that we update the interval:\n`schedule`, `bulkSchedule`, `update`, `bulkUpdate` and\n`bulkPartialUpdate`\n\nFor the bulk operations we just skip the task with invalid interval, for\nschedule and update throw an error and stop the execution.\n\n## To verify:\nCreate a rule with connector.\nLet it run for a while.\nThen update the rule.\n\nThere shouldn't be any error.","sha":"723fcc335210fa68c37e7db63c35c1530ec5f1d7"}},"sourceBranch":"main","suggestedTargetBranches":["8.19"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/222486","number":222486,"mergeCommit":{"message":"Validate interval when a task is updated (#222486)\n\nResolves: #213391\n\nThis PR adds validation for task interval where it is updated.\n\nThere are 5 places in the TaskStore that we update the interval:\n`schedule`, `bulkSchedule`, `update`, `bulkUpdate` and\n`bulkPartialUpdate`\n\nFor the bulk operations we just skip the task with invalid interval, for\nschedule and update throw an error and stop the execution.\n\n## To verify:\nCreate a rule with connector.\nLet it run for a while.\nThen update the rule.\n\nThere shouldn't be any error.","sha":"723fcc335210fa68c37e7db63c35c1530ec5f1d7"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Ersin Erdal <92688503+ersin-erdal@users.noreply.github.com>
akowalska622
pushed a commit
to akowalska622/kibana
that referenced
this pull request
Jun 25, 2025
Resolves: elastic#213391 This PR adds validation for task interval where it is updated. There are 5 places in the TaskStore that we update the interval: `schedule`, `bulkSchedule`, `update`, `bulkUpdate` and `bulkPartialUpdate` For the bulk operations we just skip the task with invalid interval, for schedule and update throw an error and stop the execution. ## To verify: Create a rule with connector. Let it run for a while. Then update the rule. There shouldn't be any error.
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.
Resolves: #213391
This PR adds validation for task interval where it is updated.
There are 5 places in the TaskStore that we update the interval:
schedule,bulkSchedule,update,bulkUpdateandbulkPartialUpdateFor the bulk operations we just skip the task with invalid interval, for schedule and update throw an error and stop the execution.
To verify:
Create a rule with connector.
Let it run for a while.
Then update the rule.
There shouldn't be any error.