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

[Search][Onboarding] Index Details - No Data view #193637

Conversation

TattdCodeMonkey
Copy link
Contributor

@TattdCodeMonkey TattdCodeMonkey commented Sep 20, 2024

Summary

Introduction of the No Data view for the index details Data tab.

Screenshots

Index without data or mapping
image

Index with mappings but no Data
image

Checklist

@TattdCodeMonkey TattdCodeMonkey added release_note:skip Skip the PR/issue when compiling release notes v9.0.0 Team:Search backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) labels Sep 20, 2024
@TattdCodeMonkey TattdCodeMonkey requested a review from a team as a code owner September 20, 2024 20:39
@TattdCodeMonkey TattdCodeMonkey changed the title Search indices/index details no data [Search][Onboarding] Index Details - No Data view Sep 20, 2024
@TattdCodeMonkey TattdCodeMonkey force-pushed the search-indices/index-details-no-data branch from 6c6e187 to ddda82c Compare September 23, 2024 17:11
const indexHasMappings = Object.keys(mappingProperties).length > 0;

// TODO: initing this should be dynamic and possibly saved in the form state
const [selectedLanguage, setSelectedLanguage] = useState<AvailableLanguages>('python');
Copy link
Member

Choose a reason for hiding this comment

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

I wonder if for now we store this option in localstorage and have a hook so the selected language is consistent everywhere.

Ideally i would love a user preference for this that also part of the dev console code exporter too.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I want to say the dev console is doing this, let me check where they are storing that and maybe we use that.

The bigger difference will be they have an explicit "set as default" option, so I'm not 100% sure if we'd want to update that value if we change it here. But if that value is set we could default to the same language?

Either way I want to write a utility function for find the default language and we can iterate on the logic for that.

Copy link
Member

Choose a reason for hiding this comment

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

yep - I think the bigger issue if we do nothing is that create-index selected option could be different from the search-detail and feel like a bug so having a utility function to find the selected language (whether default or user selected) makes sense and we can iterate to have more awareness of dev-console preferences.

Copy link
Member

@joemcelroy joemcelroy left a comment

Choose a reason for hiding this comment

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

the code generation looks great!

@kibanamachine
Copy link
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#6999

[✅] x-pack/test_serverless/functional/test_suites/search/config.feature_flags.ts: 25/25 tests passed.

see run history

@TattdCodeMonkey TattdCodeMonkey force-pushed the search-indices/index-details-no-data branch from bad9588 to 4389368 Compare September 23, 2024 21:18
@TattdCodeMonkey TattdCodeMonkey force-pushed the search-indices/index-details-no-data branch from 4389368 to 3decca2 Compare September 25, 2024 13:20
@TattdCodeMonkey TattdCodeMonkey enabled auto-merge (squash) September 25, 2024 13:53
@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
searchIndices 171 179 +8

Async chunks

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

id before after diff
searchIndices 84.7KB 89.0KB +4.3KB

Page load bundle

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

id before after diff
searchIndices 5.5KB 5.6KB +44.0B
Unknown metric groups

async chunk count

id before after diff
searchIndices 3 4 +1

History

  • 💛 Build #236506 was flaky 43893686a0fe219e6450c6bcd4df77abb3c0a849
  • 💚 Build #236484 succeeded abfba66934ac38d9488ba371833cc3ae0e59c803
  • 💛 Build #236458 was flaky ddda82c85a2e47b54f802adc801558affc0c93c2
  • 💚 Build #236120 succeeded 6c6e18796ba67e65b89890df2eff3fc4e3f1a5bc

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

@TattdCodeMonkey TattdCodeMonkey merged commit 0be74e9 into elastic:main Sep 25, 2024
20 checks passed
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Sep 25, 2024
## Summary

Introduction of the No Data view for the index details Data tab.

### Screenshots
Index without data or mapping

![image](https://github.com/user-attachments/assets/98826d3d-ea2c-434a-9648-35a2098a08e7)

Index with mappings but no Data

![image](https://github.com/user-attachments/assets/16c9f84f-868e-4ccd-9125-2fbef5c275c6)

### Checklist

- [x] 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/packages/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
- [x] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [x] Any UI touched in this PR is usable by keyboard only (learn more
about [keyboard accessibility](https://webaim.org/techniques/keyboard/))
- [ ] Any UI touched in this PR does not create any new axe failures
(run axe in browser:
[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),
[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))

(cherry picked from commit 0be74e9)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.x

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 Sep 25, 2024
…94023)

# Backport

This will backport the following commits from `main` to `8.x`:
- [[Search][Onboarding] Index Details - No Data view
(#193637)](#193637)

<!--- Backport version: 9.4.3 -->

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

<!--BACKPORT [{"author":{"name":"Rodney
Norris","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-09-25T14:40:15Z","message":"[Search][Onboarding]
Index Details - No Data view (#193637)\n\n## Summary\r\n\r\nIntroduction
of the No Data view for the index details Data tab.\r\n\r\n###
Screenshots\r\nIndex without data or
mapping\r\n\r\n![image](https://github.com/user-attachments/assets/98826d3d-ea2c-434a-9648-35a2098a08e7)\r\n\r\nIndex
with mappings but no
Data\r\n\r\n![image](https://github.com/user-attachments/assets/16c9f84f-868e-4ccd-9125-2fbef5c275c6)\r\n\r\n###
Checklist\r\n\r\n- [x] Any text added follows [EUI's
writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing),
uses\r\nsentence case text and includes
[i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n-
[
]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas
added for features that require explanation or tutorials\r\n- [x] [Unit
or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n- [x] [Flaky
Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1)
was\r\nused on any tests changed\r\n- [x] Any UI touched in this PR is
usable by keyboard only (learn more\r\nabout [keyboard
accessibility](https://webaim.org/techniques/keyboard/))\r\n- [ ] Any UI
touched in this PR does not create any new axe failures\r\n(run axe in
browser:\r\n[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),\r\n[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))","sha":"0be74e9364134362f3e9a8064a94a5a744bea4fb","branchLabelMapping":{"^v9.0.0$":"main","^v8.16.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","Team:Search","backport:prev-minor"],"title":"[Search][Onboarding]
Index Details - No Data
view","number":193637,"url":"https://github.com/elastic/kibana/pull/193637","mergeCommit":{"message":"[Search][Onboarding]
Index Details - No Data view (#193637)\n\n## Summary\r\n\r\nIntroduction
of the No Data view for the index details Data tab.\r\n\r\n###
Screenshots\r\nIndex without data or
mapping\r\n\r\n![image](https://github.com/user-attachments/assets/98826d3d-ea2c-434a-9648-35a2098a08e7)\r\n\r\nIndex
with mappings but no
Data\r\n\r\n![image](https://github.com/user-attachments/assets/16c9f84f-868e-4ccd-9125-2fbef5c275c6)\r\n\r\n###
Checklist\r\n\r\n- [x] Any text added follows [EUI's
writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing),
uses\r\nsentence case text and includes
[i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n-
[
]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas
added for features that require explanation or tutorials\r\n- [x] [Unit
or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n- [x] [Flaky
Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1)
was\r\nused on any tests changed\r\n- [x] Any UI touched in this PR is
usable by keyboard only (learn more\r\nabout [keyboard
accessibility](https://webaim.org/techniques/keyboard/))\r\n- [ ] Any UI
touched in this PR does not create any new axe failures\r\n(run axe in
browser:\r\n[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),\r\n[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))","sha":"0be74e9364134362f3e9a8064a94a5a744bea4fb"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/193637","number":193637,"mergeCommit":{"message":"[Search][Onboarding]
Index Details - No Data view (#193637)\n\n## Summary\r\n\r\nIntroduction
of the No Data view for the index details Data tab.\r\n\r\n###
Screenshots\r\nIndex without data or
mapping\r\n\r\n![image](https://github.com/user-attachments/assets/98826d3d-ea2c-434a-9648-35a2098a08e7)\r\n\r\nIndex
with mappings but no
Data\r\n\r\n![image](https://github.com/user-attachments/assets/16c9f84f-868e-4ccd-9125-2fbef5c275c6)\r\n\r\n###
Checklist\r\n\r\n- [x] Any text added follows [EUI's
writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing),
uses\r\nsentence case text and includes
[i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n-
[
]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas
added for features that require explanation or tutorials\r\n- [x] [Unit
or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n- [x] [Flaky
Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1)
was\r\nused on any tests changed\r\n- [x] Any UI touched in this PR is
usable by keyboard only (learn more\r\nabout [keyboard
accessibility](https://webaim.org/techniques/keyboard/))\r\n- [ ] Any UI
touched in this PR does not create any new axe failures\r\n(run axe in
browser:\r\n[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),\r\n[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))","sha":"0be74e9364134362f3e9a8064a94a5a744bea4fb"}}]}]
BACKPORT-->

Co-authored-by: Rodney Norris <[email protected]>
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:Search v8.16.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants