[Synthetics] Added task to sync global parameters when they are added, edited or deleted#216015
[Synthetics] Added task to sync global parameters when they are added, edited or deleted#216015cesco-f merged 15 commits intoelastic:mainfrom
Conversation
|
Pinging @elastic/obs-ux-management-team (Team:obs-ux-management) |
3c5b42b to
e3e6ce4
Compare
3d870cb to
7a1813e
Compare
x-pack/test/plugin_api_integration/test_suites/task_manager/check_registered_task_types.ts
Outdated
Show resolved
Hide resolved
...utions/observability/plugins/synthetics/server/tasks/sync_private_locations_monitors_task.ts
Outdated
Show resolved
Hide resolved
...utions/observability/plugins/synthetics/server/tasks/sync_private_locations_monitors_task.ts
Outdated
Show resolved
Hide resolved
kdelemme
left a comment
There was a problem hiding this comment.
I have a question about the need for scheduled interval vs ad-hoc scheduling of the task, but otherwise LGTM.
Just one comment about the lastStartedAt state set in case of error
...utions/observability/plugins/synthetics/server/tasks/sync_private_locations_monitors_task.ts
Show resolved
Hide resolved
...utions/observability/plugins/synthetics/server/tasks/sync_private_locations_monitors_task.ts
Show resolved
Hide resolved
pmuellr
left a comment
There was a problem hiding this comment.
No blockers, but left some comments that would probably be useful to address.
Just so I understand, there will only ever be one task created, which will - based on other activity - be run with runSoon(). And otherwise will be on a 10m interval.
...utions/observability/plugins/synthetics/server/tasks/sync_private_locations_monitors_task.ts
Outdated
Show resolved
Hide resolved
...utions/observability/plugins/synthetics/server/tasks/sync_private_locations_monitors_task.ts
Show resolved
Hide resolved
...k/solutions/observability/plugins/synthetics/server/synthetics_service/synthetics_service.ts
Outdated
Show resolved
Hide resolved
74bff86 to
18da351
Compare
…eck_registered_task_types.ts
…/sync_private_locations_monitors_task.ts
…/sync_private_locations_monitors_task.ts
also improved TS
💚 Build Succeeded
Metrics [docs]Async chunks
History
|
|
Starting backport for target branches: 8.19 https://github.com/elastic/kibana/actions/runs/15182080803 |
💔 All backports failed
Manual backportTo create the backport manually run: Questions ?Please refer to the Backport tool documentation |
…, edited or deleted (elastic#216015) This will improve PR elastic#216197. A new task is created using the task manager every time a global parameter is created, edited or deleted. When params is updated/remove/added it will sync task soon, and task also continue to run every 10 minutes. ### Execution In the task we check if params have been changed since last run or param total have changes since last run, in that case we sync private locations data with package polices ## Testing Add few browser synthetics monitors in a test private location Add/Update or delete a param , make sure relevant agent policy is updated with params. Go to fleet agent policy, view agent policy yaml and notice params field for a browser monitor in yaml. --------- Co-authored-by: Shahzad <shahzad31comp@gmail.com> (cherry picked from commit 0a838e4) # Conflicts: # x-pack/solutions/observability/plugins/synthetics/server/routes/settings/sync_global_params.ts # x-pack/solutions/observability/plugins/synthetics/server/synthetics_service/sync_global_params.ts # x-pack/solutions/observability/plugins/synthetics/server/synthetics_service/synthetics_monitor/synthetics_monitor_client.ts
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…, edited or deleted (elastic#216015) This will improve PR elastic#216197. A new task is created using the task manager every time a global parameter is created, edited or deleted. When params is updated/remove/added it will sync task soon, and task also continue to run every 10 minutes. In the task we check if params have been changed since last run or param total have changes since last run, in that case we sync private locations data with package polices Add few browser synthetics monitors in a test private location Add/Update or delete a param , make sure relevant agent policy is updated with params. Go to fleet agent policy, view agent policy yaml and notice params field for a browser monitor in yaml. --------- Co-authored-by: Shahzad <shahzad31comp@gmail.com> (cherry picked from commit 0a838e4)
…, edited or deleted (elastic#216015) This will improve PR elastic#216197. A new task is created using the task manager every time a global parameter is created, edited or deleted. When params is updated/remove/added it will sync task soon, and task also continue to run every 10 minutes. In the task we check if params have been changed since last run or param total have changes since last run, in that case we sync private locations data with package polices Add few browser synthetics monitors in a test private location Add/Update or delete a param , make sure relevant agent policy is updated with params. Go to fleet agent policy, view agent policy yaml and notice params field for a browser monitor in yaml. --------- Co-authored-by: Shahzad <shahzad31comp@gmail.com> (cherry picked from commit 0a838e4)
…, edited or deleted (elastic#216015) This will improve PR elastic#216197. A new task is created using the task manager every time a global parameter is created, edited or deleted. When params is updated/remove/added it will sync task soon, and task also continue to run every 10 minutes. In the task we check if params have been changed since last run or param total have changes since last run, in that case we sync private locations data with package polices Add few browser synthetics monitors in a test private location Add/Update or delete a param , make sure relevant agent policy is updated with params. Go to fleet agent policy, view agent policy yaml and notice params field for a browser monitor in yaml. --------- Co-authored-by: Shahzad <shahzad31comp@gmail.com> (cherry picked from commit 0a838e4)
…e added, edited or deleted (#216015) (#221243) # Backport This will backport the following commits from `main` to `8.19`: - [[Synthetics] Added task to sync global parameters when they are added, edited or deleted (#216015)](#216015) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Francesco Fagnani","email":"fagnani.francesco@gmail.com"},"sourceCommit":{"committedDate":"2025-05-22T08:43:57Z","message":"[Synthetics] Added task to sync global parameters when they are added, edited or deleted (#216015)\n\nThis will improve PR #216197.\n\nA new task is created using the task manager every time a global\nparameter is created, edited or deleted.\n\nWhen params is updated/remove/added it will sync task soon, and task\nalso continue to run every 10 minutes.\n\n\n### Execution\n\nIn the task we check if params have been changed since last run or param\ntotal have changes since last run, in that case we sync private\nlocations data with package polices\n\n## Testing\n\nAdd few browser synthetics monitors in a test private location\n\nAdd/Update or delete a param , make sure relevant agent policy is\nupdated with params. Go to fleet agent policy, view agent policy yaml\nand notice params field for a browser monitor in yaml.\n\n---------\n\nCo-authored-by: Shahzad <shahzad31comp@gmail.com>","sha":"0a838e43883e83a42defc4f5840829c10223f820","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:obs-ux-management","backport:version","v9.1.0","v8.19.0"],"title":"[Synthetics] Added task to sync global parameters when they are added, edited or deleted","number":216015,"url":"https://github.com/elastic/kibana/pull/216015","mergeCommit":{"message":"[Synthetics] Added task to sync global parameters when they are added, edited or deleted (#216015)\n\nThis will improve PR #216197.\n\nA new task is created using the task manager every time a global\nparameter is created, edited or deleted.\n\nWhen params is updated/remove/added it will sync task soon, and task\nalso continue to run every 10 minutes.\n\n\n### Execution\n\nIn the task we check if params have been changed since last run or param\ntotal have changes since last run, in that case we sync private\nlocations data with package polices\n\n## Testing\n\nAdd few browser synthetics monitors in a test private location\n\nAdd/Update or delete a param , make sure relevant agent policy is\nupdated with params. Go to fleet agent policy, view agent policy yaml\nand notice params field for a browser monitor in yaml.\n\n---------\n\nCo-authored-by: Shahzad <shahzad31comp@gmail.com>","sha":"0a838e43883e83a42defc4f5840829c10223f820"}},"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/216015","number":216015,"mergeCommit":{"message":"[Synthetics] Added task to sync global parameters when they are added, edited or deleted (#216015)\n\nThis will improve PR #216197.\n\nA new task is created using the task manager every time a global\nparameter is created, edited or deleted.\n\nWhen params is updated/remove/added it will sync task soon, and task\nalso continue to run every 10 minutes.\n\n\n### Execution\n\nIn the task we check if params have been changed since last run or param\ntotal have changes since last run, in that case we sync private\nlocations data with package polices\n\n## Testing\n\nAdd few browser synthetics monitors in a test private location\n\nAdd/Update or delete a param , make sure relevant agent policy is\nupdated with params. Go to fleet agent policy, view agent policy yaml\nand notice params field for a browser monitor in yaml.\n\n---------\n\nCo-authored-by: Shahzad <shahzad31comp@gmail.com>","sha":"0a838e43883e83a42defc4f5840829c10223f820"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Shahzad <shahzad31comp@gmail.com>
…, edited or deleted (elastic#216015) This will improve PR elastic#216197. A new task is created using the task manager every time a global parameter is created, edited or deleted. When params is updated/remove/added it will sync task soon, and task also continue to run every 10 minutes. ### Execution In the task we check if params have been changed since last run or param total have changes since last run, in that case we sync private locations data with package polices ## Testing Add few browser synthetics monitors in a test private location Add/Update or delete a param , make sure relevant agent policy is updated with params. Go to fleet agent policy, view agent policy yaml and notice params field for a browser monitor in yaml. --------- Co-authored-by: Shahzad <shahzad31comp@gmail.com>
This will improve PR #216197.
A new task is created using the task manager every time a global parameter is created, edited or deleted.
When params is updated/remove/added it will sync task soon, and task also continue to run every 10 minutes.
Execution
In the task we check if params have been changed since last run or param total have changes since last run, in that case we sync private locations data with package polices
Testing
Add few browser synthetics monitors in a test private location
Add/Update or delete a param , make sure relevant agent policy is updated with params. Go to fleet agent policy, view agent policy yaml and notice params field for a browser monitor in yaml.