-
Notifications
You must be signed in to change notification settings - Fork 845
Change non-boolean enabled configs to mode #12409
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
Conversation
acd70c4 to
cc8a02d
Compare
maskit
left a comment
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.
The description makes sense. Just one possible error in the change.
e78cef8 to
dad9c30
Compare
Most "enabled" configurations are booleans that toggle on or off a feature. But we have a few that are named "enabled" but actually take an enumeration of values to control behavior. This is confusing terminology. This patch keeps support for the enabled configuration as currently named, adds a new "mode" configuration for these, and deprecates the old "enabled" config in the docs. proxy.config.ssl.session_cache.enabled was somewhat complicated: with the 10.0.0 release, we implemented it as "value" to try to address the issue of this patch just for that parameter, but kept the "enabled" config description in the docs. So the docs were out of sync with the code. This adds support for "enabled" and immediately deprecates that, since users may have tried to use that, silently keeps support for "value" in case that was used, and adds the now desired "mode" configuration. If a user passes both the deprecated "enabled" config as well as the new "mode" config, then they must be the same value, otherwise an Emergency message is logged because it is impossible for ATS to discern which value should be used. Aside from this Emergency log on mismatch just mentioned, this patch should be backwards compatible without introducing any changes in behavior for current configs. Fixes: apache#11901
dad9c30 to
5e3b082
Compare
|
It seems some of the autest got caught up into the new Linking this as it had some discussion related to this. |
|
100% onboard with this change. The output would be: I think would be a good idea, having some mapping for this so if you hit one of the variables in that mapping you could get an error, like: We could even have this inside ATS, but not sure how far we wanna go. |
|
After crawling in the weeds for a while, I think this will be better for the user as a simple rename in 11.x, rather than trying to support both in 10.x: |
Most "enabled" configurations are booleans that toggle on or off a feature. But we have a few that are named "enabled" but actually take an enumeration of values to control behavior. This is confusing terminology. This patch keeps support for the enabled configuration as currently named, adds a new "mode" configuration for these, and deprecates the old "enabled" config in the docs.
proxy.config.ssl.session_cache.enabled was somewhat complicated: with the 10.0.0 release, we implemented it as "value" to try to address the issue of this patch just for that parameter, but kept the "enabled" config description in the docs. So the docs were out of sync with the code. This adds support for "enabled" and immediately deprecates that, since users may have tried to use that, silently keeps support for "value" in case that was used, and adds the now desired "mode" configuration.
If a user passes both the deprecated "enabled" config as well as the new "mode" config, then they must be the same value, otherwise an Emergency message is logged because it is impossible for ATS to discern which value should be used.
Aside from this Emergency log on mismatch just mentioned, this patch should be backwards compatible without introducing any changes in behavior for current configs.
Fixes: #11901