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

Deprecate kibana.index setting #83988

Merged
merged 10 commits into from
Nov 24, 2020
Merged

Conversation

kobelb
Copy link
Contributor

@kobelb kobelb commented Nov 20, 2020

Using the ela.st service for the deprecation message and the release-note, so we can redirect this to a blog-post with more information as we get closer to the 8.0 release.

Resolves #82521

"Release Note: Deprecating the kibana.index setting. Multitenancy by changing kibana.index will not be supported starting in 8.0. See https://ela.st/kbn-remove-legacy-multitenancy for more details"

@kobelb kobelb requested a review from a team as a code owner November 20, 2020 21:24
@kobelb
Copy link
Contributor Author

kobelb commented Nov 20, 2020

@elasticmachine merge upstream

@kobelb kobelb changed the title Deprecate kibana.index setting Deprecate kibana.index setting Nov 20, 2020
Comment on lines 29 to 31
log(
`Setting [kibana.index] is deprecated. Multitenancy by changing 'kibana.index' will not be supported starting in 8.0. See https://ela.st/kbn-remove-legacy-multitenancy for more details`
);
Copy link
Contributor

Choose a reason for hiding this comment

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

Remark: There is an inconsistency with the wording of our unused factory:

log(`${fullPath} is deprecated and is no longer used`);

Setting [{config prop}] is deprecated vs {config prop} is deprecated.

I also see that rename is using double quote around the config prop (where unused does not).

log(`"${fullOldPath}" is deprecated and has been replaced by "${fullNewPath}"`);

This is minor, but we might want to be consistent in our deprecation messages.

Also thinking: we may want to adapt ConfigDeprecationFactory.unused (and others) to accept a new optional 'message' parameter. That would also to log custom messages in deprecations without having to recode a custom one just to log the message (as it is done here for kibana.index).

unused('kibana.index', "Multitenancy by changing 'kibana.index' will not be supported starting in 8.0. See https://ela.st/kbn-remove-legacy-multitenancy for more details")

This is probably out of the scope of this PR though. Should I create a separate issue?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is minor, but we might want to be consistent in our deprecation messages.

Agreed about being consistent here. I was originally replicating the format from the following deprecation log message, because I incorrectly assumed it used the "standard approach": [warning][config][deprecation] Setting [elasticsearch.username] to "kibana" is deprecated. You should use the "kibana_system" user instead.

Do we want to follow the precedent set by unused and not use double-quotes, or should we follow the precedent set by rename and use double-quotes?

Also thinking: we may want to adapt ConfigDeprecationFactory.unused (and others) to accept a new optional 'message' parameter. That would also to log custom messages in deprecations without having to recode a custom one just to log the message (as it is done here for kibana.index).

I think it's fine to support custom messages for unused/rename. However, I don't think we should be using the unused deprecation here, as this setting is still being used and has an effect, it's just deprecated. We use the unused deprecation elsewhere when settings don't have an effect.

Copy link
Contributor

Choose a reason for hiding this comment

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

Do we want to follow the precedent set by unused and not use double-quotes, or should we follow the precedent set by rename and use double-quotes?

I think using quotes is slightly better, wdyt?

I think it's fine to support custom messages for unused/rename. However, I don't think we should be using the unused deprecation here, as this setting is still being used and has an effect, it's just deprecated.

Yea, you're right. I forgot we are still using the value of this property. Nevermind

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Double-quotes sound good to me! I just independently decided that also and used it in 9dc7532

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

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

@kobelb kobelb merged commit 13808e0 into elastic:master Nov 24, 2020
@kobelb kobelb deleted the deprecate-kibana-index branch November 24, 2020 20:28
kobelb added a commit that referenced this pull request Nov 25, 2020
* Deprecating `kibana.index` setting

* Using ela.st service so this can be changed to the blog in the future

* Adding unit tests

* Revising deprecation log message

* Changing the deprecation log message to be more consistent with others

* Updating kibana.index docs also

* Using rename deprecation as the "standard" for the deprecation messages

* /s/'/`
@cjcenizal cjcenizal added the Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc label Sep 27, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-core (Team:Core)

@azasypkin azasypkin mentioned this pull request Mar 29, 2023
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release_note:deprecation Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc v7.11.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecate kibana.index setting
5 participants