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

[Enterprise Search] Fix support for cron scheduling for Elastic Crawler Indices #146357

Merged

Conversation

byronhulcher
Copy link
Contributor

@byronhulcher byronhulcher commented Nov 28, 2022

Summary

  1. Makes sure that enabled: true is set consistently with the use_connecter_schedule prop stored in Crawler2's connector schedule
  2. Prefer cron schedule over crawler schedule when a user enables scheduling

Checklist

@byronhulcher byronhulcher added release_note:skip Skip the PR/issue when compiling release notes Team:EnterpriseSearch backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) labels Nov 28, 2022
@byronhulcher byronhulcher self-assigned this Nov 28, 2022
@byronhulcher byronhulcher changed the title [Enterprise Search] Prefer cron scheduling for crawler indices when enabling scheduling [Enterprise Search] Fix support for cron scheduling for Elastic Crawler Indices Nov 28, 2022
@byronhulcher byronhulcher marked this pull request as ready for review November 28, 2022 14:27
@byronhulcher byronhulcher requested a review from a team November 28, 2022 14:27
setUseConnectorSchedule: actions.saveChanges,
toggleCrawlAutomatically: actions.saveChanges,
submitConnectorSchedule: async ({ scheduling }) => {
try {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: this won't work as makeUpdateConnectorSchedulingRequest will always succeed. Need to listen for the error action instead.

@byronhulcher byronhulcher enabled auto-merge (squash) November 28, 2022 15:02
@byronhulcher
Copy link
Contributor Author

@elasticmachine merge upstream

@byronhulcher
Copy link
Contributor Author

@elasticmachine merge upstream

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
enterpriseSearch 2.0MB 2.0MB +575.0B
Unknown metric groups

ESLint disabled in files

id before after diff
osquery 1 2 +1

ESLint disabled line counts

id before after diff
enterpriseSearch 19 21 +2
fleet 59 65 +6
osquery 109 115 +6
securitySolution 442 448 +6
total +20

Total ESLint disabled count

id before after diff
enterpriseSearch 20 22 +2
fleet 68 74 +6
osquery 110 117 +7
securitySolution 519 525 +6
total +21

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @byronhulcher

@byronhulcher byronhulcher merged commit 5b79dbe into elastic:main Nov 28, 2022
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Nov 28, 2022
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.6

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 Nov 28, 2022
… Crawler Indices (#146357) (#146463)

# Backport

This will backport the following commits from `main` to `8.6`:
- [[Enterprise Search] Fix support for cron scheduling for Elastic
Crawler Indices
(#146357)](#146357)

<!--- Backport version: 8.9.7 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Byron
Hulcher","email":"byronhulcher@gmail.com"},"sourceCommit":{"committedDate":"2022-11-28T19:13:08Z","message":"[Enterprise
Search] Fix support for cron scheduling for Elastic Crawler Indices
(#146357)","sha":"5b79dbea96c9e4694cec2e47d87b1bcbea6740b5","branchLabelMapping":{"^v8.7.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:EnterpriseSearch","backport:prev-minor","v8.6.0","v8.7.0"],"number":146357,"url":"https://github.com/elastic/kibana/pull/146357","mergeCommit":{"message":"[Enterprise
Search] Fix support for cron scheduling for Elastic Crawler Indices
(#146357)","sha":"5b79dbea96c9e4694cec2e47d87b1bcbea6740b5"}},"sourceBranch":"main","suggestedTargetBranches":["8.6"],"targetPullRequestStates":[{"branch":"8.6","label":"v8.6.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.7.0","labelRegex":"^v8.7.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/146357","number":146357,"mergeCommit":{"message":"[Enterprise
Search] Fix support for cron scheduling for Elastic Crawler Indices
(#146357)","sha":"5b79dbea96c9e4694cec2e47d87b1bcbea6740b5"}}]}]
BACKPORT-->

Co-authored-by: Byron Hulcher <byronhulcher@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) release_note:skip Skip the PR/issue when compiling release notes Team:EnterpriseSearch v8.6.0 v8.7.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants