Skip to content

[Index Management] Add option to convert to lookup index in the manage index dropdown#233998

Merged
damian-polewski merged 38 commits intoelastic:mainfrom
damian-polewski:index_management/add_option_to_convert_to_lookup_in_manage_dropdown
Sep 23, 2025
Merged

[Index Management] Add option to convert to lookup index in the manage index dropdown#233998
damian-polewski merged 38 commits intoelastic:mainfrom
damian-polewski:index_management/add_option_to_convert_to_lookup_in_manage_dropdown

Conversation

@damian-polewski
Copy link
Contributor

@damian-polewski damian-polewski commented Sep 4, 2025

Summary

Closes #233996

This PR introduces the core logic and UI for converting an index to a lookup index in Index Management, including a custom React hook, modal enhancements, and integration of the reindex service.

Changes:

  • Added an option to convert an index to a lookup index in the manage index dropdown.
  • Aligned the ConvertIndexToLookupModal with latest design.
  • Added a new useConvertIndexToLookup hook to handle the conversion logic.
  • Integrated the reindexService with index_management plugin.
  • Updated the fetchIndicesCall to return settings.index.mode of the index.

Demo

Screen.Recording.2025-09-11.at.10.56.16.mov

How to test

  1. Create an index that meets requirements (less than 2 billion docs, single shard).

Note

If the index does not meet the requirements, the button will be disabled. For indices that already have a lookup mode, the button will not be visible at all.

  1. Navigate to index list and select the created index
  2. Select Convert to lookup index option from the Manage index dropdown
  3. Change the new lookup index name if needed and press Convert
  4. After conversion is done you will be navigated to the lookup index's details page

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.

Release Note

Adds an option to convert an index to a lookup index in the manage index dropdown.

@damian-polewski damian-polewski self-assigned this Sep 4, 2025
@damian-polewski damian-polewski added Feature:Index Management Index and index templates UI Team:Kibana Management Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more t// backport:skip This PR does not require backporting labels Sep 4, 2025
@damian-polewski damian-polewski changed the title [Index Management] Sep 4, 2025
@damian-polewski damian-polewski marked this pull request as ready for review September 11, 2025 09:28
@damian-polewski damian-polewski requested review from a team as code owners September 11, 2025 09:28
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-management (Team:Kibana Management)

@damian-polewski damian-polewski requested a review from a team September 11, 2025 09:32
@damian-polewski
Copy link
Contributor Author

Hi @elastic/docs I wanted to ask about your opinion on the copy, especially around "Convert to lookup index". I'm wondering if the current version is good from your side or if you would prefer to call this action differently.
Let me know what do you think!

Copy link
Contributor

@florent-leborgne florent-leborgne left a comment

Choose a reason for hiding this comment

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

Some small copy suggestions. Some might not work due to space constraints. Lmk what you think.

Edit: just saw your question, "Convert to lookup index" sounds good to me. I'm wondering if we should highlight somewhere what are the main differences when an index is in lookup mode.

@damian-polewski damian-polewski requested a review from a team September 11, 2025 10:56
Copy link

@jovana-andjelkovic jovana-andjelkovic left a comment

Choose a reason for hiding this comment

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

@damian-polewski
Copy link
Contributor Author

Some small copy suggestions. Some might not work due to space constraints. Lmk what you think.

Edit: just saw your question, "Convert to lookup index" sounds good to me. I'm wondering if we should highlight somewhere what are the main differences when an index is in lookup mode.

Hi @florent-leborgne, thank you for the feedback!
Regarding your question about differences when an index is in lookup mode - @jovana-andjelkovic maybe we could link some documentation somewhere so the user can read up on lookup indices?

@damian-polewski
Copy link
Contributor Author

During yesterday's team sync meeting we noticed that user can close the conversion modal and delete the source index which stops the reindex operation. This is also the case when reindexing documents in Upgrade Assistant - right after the reindexing starts user can navigate to Index Management and delete the index. After discussing this with @jovana-andjelkovic we decided to update the description in the confirm deletion modal to inform the user that the index deletion also affects reindexing operation.

@florent-leborgne could you please take a look at the new copy added?

List of changes:

  1. Added description to the conversion modal.
Screenshot 2025-09-18 at 16 04 14
  1. Added a toast when user closes the modal with the x button and the reindexing is in progress.
Screenshot 2025-09-18 at 16 05 15
  1. Added information about index deletion affecting ongoing reindex operations.
Screenshot 2025-09-18 at 16 04 04

cc @alisonelizabeth

Copy link
Contributor

@florent-leborgne florent-leborgne left a comment

Choose a reason for hiding this comment

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

Hi! Took a look at the new copy 👀

@damian-polewski damian-polewski removed ci:project-deploy-elasticsearch Create an Elasticsearch Serverless project ci:project-deploy-security Create a Security Serverless Project labels Sep 19, 2025
@mattkime
Copy link
Contributor

mattkime commented Sep 22, 2025

Previously, the reindexing service always created a unique pattern for new indices but now anything can be provided. It should make a check using the resolve api to see if the new index name matches an existing index. We should also figure out how we wish to address this in the UI, although we might address it as a follow up task.

@mattkime
Copy link
Contributor

Created this pr to catch attempts to reindex to an existing index - #236011

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
indexManagement 665 672 +7
upgradeAssistant 181 182 +1
total +8

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/index-management-shared-types 149 150 +1
@kbn/upgrade-assistant-pkg-common 10 11 +1
indexManagement 250 253 +3
reindexService 55 54 -1
total +4

Async chunks

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

id before after diff
indexManagement 688.6KB 695.7KB +7.0KB
upgradeAssistant 228.7KB 228.1KB -569.0B
total +6.5KB

Page load bundle

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

id before after diff
indexManagement 31.8KB 32.0KB +113.0B
reindexService 3.3KB 3.1KB -216.0B
total -103.0B
Unknown metric groups

API count

id before after diff
@kbn/index-management-shared-types 149 150 +1
@kbn/upgrade-assistant-pkg-common 10 11 +1
indexManagement 255 258 +3
reindexService 62 61 -1
total +4

History

cc @damian-polewski

@damian-polewski damian-polewski merged commit 20420e9 into elastic:main Sep 23, 2025
13 checks passed
CAWilson94 pushed a commit to CAWilson94/kibana that referenced this pull request Sep 24, 2025
…e index dropdown (elastic#233998)

## Summary

Closes elastic#233996

This PR introduces the core logic and UI for converting an index to a
lookup index in Index Management, including a custom React hook, modal
enhancements, and integration of the reindex service.
niros1 pushed a commit that referenced this pull request Sep 30, 2025
…e index dropdown (#233998)

## Summary

Closes #233996

This PR introduces the core logic and UI for converting an index to a
lookup index in Index Management, including a custom React hook, modal
enhancements, and integration of the reindex service.
rylnd pushed a commit to rylnd/kibana that referenced this pull request Oct 17, 2025
…e index dropdown (elastic#233998)

## Summary

Closes elastic#233996

This PR introduces the core logic and UI for converting an index to a
lookup index in Index Management, including a custom React hook, modal
enhancements, and integration of the reindex service.
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 Feature:Index Management Index and index templates UI needs_docs release_note:enhancement Team:Kibana Management Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more t// v9.2.0