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

[Connectors] Use Connector API to cancel all syncs #183924

Merged
merged 5 commits into from
May 27, 2024

Conversation

jedrazb
Copy link
Member

@jedrazb jedrazb commented May 21, 2024

Summary

Use Connector API to cancel all sync jobs for a connector. Slightly more overhead since we need to cancel each job separately but this is the only cancel endpoint we have as of now.

The ES logic handles pending, suspended and running jobs in a same way as kibana did, logic reference: https://github.com/elastic/elasticsearch/blob/e77613cdfc5a2b5598ff125b5881d87f9369c867/x-pack/plugin/ent-search/src/main/java/org/elasticsearch/xpack/application/connector/syncjob/ConnectorSyncJobIndexService.java#L264

ES logic also handles status transitions to guard against e.g. cancelling already completed syncs

Valdiation

Tested locally

Checklist

Delete any items that are not applicable to this PR.

@jedrazb jedrazb added release_note:skip Skip the PR/issue when compiling release notes v8.15.0 labels May 21, 2024
@jedrazb jedrazb marked this pull request as ready for review May 24, 2024 09:03
@jedrazb jedrazb requested a review from a team as a code owner May 24, 2024 09:03
Copy link
Member

@efegurkan efegurkan left a comment

Choose a reason for hiding this comment

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

LGTM

@jedrazb jedrazb enabled auto-merge (squash) May 24, 2024 13:27
@jedrazb
Copy link
Member Author

jedrazb commented May 24, 2024

@elasticmachine merge upstream

@jedrazb
Copy link
Member Author

jedrazb commented May 27, 2024

@elasticmachine merge upstream

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/search-connectors 3672 3673 +1

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.7MB 2.7MB +99.0B
serverlessSearch 474.2KB 474.2KB +8.0B
total +107.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
enterpriseSearch 49.0KB 49.0KB +50.0B
serverlessSearch 19.6KB 19.6KB +50.0B
total +100.0B
Unknown metric groups

API count

id before after diff
@kbn/search-connectors 3672 3673 +1

History

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

@jedrazb jedrazb merged commit a4f468b into elastic:main May 27, 2024
18 checks passed
@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label May 27, 2024
rshen91 pushed a commit to rshen91/kibana that referenced this pull request May 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting release_note:skip Skip the PR/issue when compiling release notes v8.15.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants