Skip to content

Crawl connectors, which finds all recently updated connector instances#280592

Open
erikcurrin-elastic wants to merge 5 commits into
elastic:mainfrom
erikcurrin-elastic:sml-crawler
Open

Crawl connectors, which finds all recently updated connector instances#280592
erikcurrin-elastic wants to merge 5 commits into
elastic:mainfrom
erikcurrin-elastic:sml-crawler

Conversation

@erikcurrin-elastic

Copy link
Copy Markdown
Contributor

Summary

Implement a crawler for connectors that recreates the SML entries for them

Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

  • Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n support
  • Documentation was added for features that require explanation or tutorials
  • Unit or functional tests were updated or added to match the most common scenarios
  • If a plugin configuration key changed, check if it needs to be allowlisted in the cloud and added to the docker list
  • This was checked for breaking HTTP API changes, and any breaking changes have been approved by the breaking-change committee. The release_note:breaking label should be applied in these situations.
  • Flaky Test Runner was used on any tests changed
  • The PR description includes the appropriate Release Notes section, and the correct release_note:* label is applied per the guidelines
  • Review the backport guidelines and apply applicable backport:* labels.

Identify risks

Does this PR introduce any risks? For example, consider risks like hard to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified risk. Invite stakeholders and evaluate how to proceed before merging.

@erikcurrin-elastic erikcurrin-elastic added release_note:skip Skip the PR/issue when compiling release notes backport:skip This PR does not require backporting Team:agent-builder labels Jul 23, 2026
@erikcurrin-elastic
erikcurrin-elastic marked this pull request as ready for review July 23, 2026 23:26
@erikcurrin-elastic
erikcurrin-elastic requested a review from a team as a code owner July 23, 2026 23:26
const soRepository = savedObjects.createInternalRepository();

// connectors are hidden, so we need action here to expose them during crawl
const soRepository = savedObjects.createInternalRepository(['action']);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This task runner is shared by all attachment types, so every crawl will depend on the hidden action type being registered.Do we want this type of access for non-connector crawls? Should they be scoped to only connector crawls?

Can we please add some tests that handle when action mappings are not preasent?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Fiddled with this, we can have the definition have an array for this (hiddenTypes I guess?). Then connectors is the only thing that sets it.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Reviewed the connector SML crawler change. The list crawler, the requiredHiddenTypes plumbing into createInternalRepository, and the added test coverage are sound and consistent with the crawler security model. One inline note on a now-stale doc comment.

Generated by Claude Reviewer for #280592 · 19.9 AIC · ⌖ 0.815 AIC

@kibanamachine

Copy link
Copy Markdown
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] Scout Lane #6 - stateful-classic / default / local-stateful-classic - Entity attachment cases – flyout add-to-case actions and Entities accordion - Entities accordion renders when entity attachments were added via API
  • [job] [logs] Scout Lane #6 - stateful-classic / default / local-stateful-classic - Entity attachment cases – flyout add-to-case actions and Entities accordion - renders no Entities accordion when a case has no entity attachments

Metrics [docs]

✅ unchanged

History

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:agent-builder

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants