-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Logs/Metrics UI] Add deprecated field configuration to Deprecations API #115103
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should remove the actual field names from the translations since those need to remain untranslated. I was going to suggest things like tiebreaker
, pod ID
, container ID
, host name
, etc but I can't decide if it's OK to translate those OR not. But the actual literal field names need to remain untranslated.
Co-authored-by: Chris Cowan <chris@chriscowan.us>
…n-api # Conflicts: # x-pack/plugins/infra/server/plugin.ts
…to 113166-deprecation-api
💔 Build Failed
Failed CI StepsTest FailuresKibana Pipeline / jest / Jest Tests.src/plugins/dashboard/public/application/hooks.Dashboard container lifecycle Old dashboard container is destroyed when new dashboardId is givenStandard Out
Stack Trace
Metrics [docs]
History
To update your PR or re-run it, just comment with: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
💔 Backport failed
To backport manually run: |
…-link-to-kibana-app * 'master' of github.com:elastic/kibana: (30 commits) Fix potential error from undefined (elastic#115562) [App Search, Crawler] Fix validation step panel padding/whitespace (elastic#115542) [Cases][Connectors] ServiceNow ITOM: MVP (elastic#114125) Change default session idle timeout to 8 hours. (elastic#115565) Upgrade EUI to v39.1.1 (elastic#114732) [App Search] Wired up organic results on Curation Suggestions view (elastic#114717) [i18n] remove i18n html extractor (elastic#115004) [Logs/Metrics UI] Add deprecated field configuration to Deprecations API (elastic#115103) [Transform] Add alerting rules management to Transform UI (elastic#115363) Update UI links to Fleet and Agent docs (elastic#115295) [ML] Adding ability to change data view in advanced job wizard (elastic#115191) Change deleteByNamespace to include legacy URL aliases (elastic#115459) [Unified Integrations] Remove and cleanup add data views (elastic#115424) [Discover] Show ignored field values (elastic#115040) [ML] Stop reading the ml.max_open_jobs node attribute (elastic#115524) [Discover] Improve doc viewer code in Discover (elastic#114759) [Security Solutions] Adds security detection rule actions as importable and exportable (elastic#115243) [Security Solution] [Platform] Migrate legacy actions whenever user interacts with the rule (elastic#115101) [Fleet] Add telemetry for integration cards (elastic#115413) 🐛 Fix single percentile case when ES is returning no buckets (elastic#115214) ... # Conflicts: # x-pack/plugins/reporting/public/management/__snapshots__/report_listing.test.tsx.snap
…API (elastic#115103) * [Logs/Metrics UI] Add deprecated field configuration to Deprecations API * Add correction steps * Add unit test for source config deprecations * Apply suggestions from code review Co-authored-by: Chris Cowan <chris@chriscowan.us> * Lint fix Co-authored-by: Chris Cowan <chris@chriscowan.us> # Conflicts: # x-pack/plugins/infra/server/plugin.ts
…API (#115103) (#115633) * [Logs/Metrics UI] Add deprecated field configuration to Deprecations API * Add correction steps * Add unit test for source config deprecations * Apply suggestions from code review Co-authored-by: Chris Cowan <chris@chriscowan.us> * Lint fix Co-authored-by: Chris Cowan <chris@chriscowan.us> # Conflicts: # x-pack/plugins/infra/server/plugin.ts
…nfiguration code (#169430) Resolves #168240 ### Changes - Removes `fields.message` from the `infrastructure-ui-source` saved object who's value was being populated by `xpack.infra.sources.default.fields.message` from config. See https://www.elastic.co/guide/en/kibana/master/logs-ui-settings-kb.html - Removes `getInternalSourceConfiguration` and `defineInternalSourceConfiguration` functions introduced in #36066 as I cannot see them being used anywhere. Stops exposing `defineInternalSourceConfiguration` as part of server plugin interface. - Removes `getStaticDefaultSourceConfiguration` from InfraSources class as we aren't using `sources` from kibana config in source configuration anymore. - Removes deprecations warning of removal in 8.0 for other fields belonging to config xpack.infra.sources.* introduced in #115103 - Removes `getAllSourceConfigurations` used only in removed deprecations file f427278#diff-081721894fc437938eb652beae0a0640ddeee532ec5e48af1f3093c8074f1eecL195 - Removed `getAllSavedSourceConfigurations` only used in `getAllSourceConfigurations` ### How to test - `infrastructure-ui-source` saved object no longer has `fields` attributes - in kibana.yml set `xpack.infra.sources.default.fields.message: ['testmessage', '@testmessage']` - go to Infra -> Settings - Change the name and save the form - view the `infrastructure-ui-source` saved object and no `fields` attribute should exist (unless it previously existed in an already existing `infrastructure-ui-source` saved object - changes do not affect`fields.message` is used in logs_shared plugin - i'm not sure how to easily test this and relying on someone with more Logs knowledge to help out, but from what I can see logs accesses the config directly (`xpack.infra.sources.default.fields.message`) and never uses the saved object field being removed.
Summary
Closes #113166
This PR adds two different types of deprecations for the Source Configuration fields:
kibana.yml
ofxpack.infra.sources.default.fields.{DEPRECATED FIELD KEY}
. This is only a warning because these values only affect anything the very first time the user runs Kibana, and don't seem to be able to update the source configuration later on.To test
Configure deprecated fields
kibana.dev.yml
, setxpack.infra.sources.default.fields.{DEPRECATED FIELD KEY}
to a different value. For example, setxpack.infra.sources.default.fields.timestamp
tonot-@timestamp
Check the Upgrade Assistant
app/management/stack/upgrade_assistant
and ensure you see warnings about the deprecated fields.Checklist
Delete any items that are not applicable to this PR.