Skip to content

[User Storage] Minor optimization to server client getAll method#268318

Merged
tsullivan merged 2 commits into
elastic:mainfrom
tsullivan:user-storage/server-get-all-optimization
May 8, 2026
Merged

[User Storage] Minor optimization to server client getAll method#268318
tsullivan merged 2 commits into
elastic:mainfrom
tsullivan:user-storage/server-get-all-optimization

Conversation

@tsullivan
Copy link
Copy Markdown
Member

@tsullivan tsullivan commented May 7, 2026

Summary

This PR implements an optimization opportunity in the getAll method implementation of the server side client in the UserStorage service.

  • Replaces two parallel soClient.get() calls (one per scope) with a single soClient.bulkGet() request
  • Deletes the readSoData helper
  • Detects missing docs via doc.error instead of catching isNotFoundError.

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.

@tsullivan tsullivan changed the title [User Storage] Minor optimization to getAll on server-side [User Storage] Minor optimization to server client getAll method May 7, 2026
@tsullivan tsullivan force-pushed the user-storage/server-get-all-optimization branch from df41840 to 5e60ed8 Compare May 7, 2026 22:37
@tsullivan tsullivan marked this pull request as ready for review May 7, 2026 22:59
@tsullivan tsullivan requested a review from a team as a code owner May 7, 2026 22:59
@tsullivan tsullivan added release_note:skip Skip the PR/issue when compiling release notes backport:skip This PR does not require backporting Team:SharedUX Platform AppEx-SharedUX (formerly Global Experience) t// labels May 7, 2026
@infra-vault-gh-plugin-prod
Copy link
Copy Markdown

Pinging @elastic/appex-sharedux (Team:SharedUX)

@tsullivan
Copy link
Copy Markdown
Member Author

/ci

@kibanamachine
Copy link
Copy Markdown
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] Scout Lane #39 - serverless-observability_complete / default / local-serverless-observability_complete - find - basic - should return 200 with individual responses
  • [job] [logs] Scout Lane #8 - stateful-classic / default / local-stateful-classic - Maps - maps telemetry - should return the correct telemetry values for map saved objects

Metrics [docs]

✅ unchanged

@tsullivan tsullivan merged commit 7051456 into elastic:main May 8, 2026
32 checks passed
clintandrewhall pushed a commit that referenced this pull request May 12, 2026
…8318)

## Summary

This PR implements an optimization opportunity in the `getAll` method
implementation of the server side client in the UserStorage service.

* Replaces two parallel soClient.get() calls (one per scope) with a
single soClient.bulkGet() request
* Deletes the readSoData helper
* Detects missing docs via doc.error instead of catching
isNotFoundError.


### 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](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)~
- ~[ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials~
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
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](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)~
- ~[ ] 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](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed~
- [x] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
- [x] Review the [backport
guidelines](https://docs.google.com/document/d/1VyN5k91e5OVumlc0Gb9RPa3h1ewuPE705nRtioPiTvY/edit?usp=sharing)
and apply applicable `backport:*` labels.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
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:SharedUX Platform AppEx-SharedUX (formerly Global Experience) t// v9.5.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants