Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion docs/root/version_history/current.rst
Original file line number Diff line number Diff line change
Expand Up @@ -107,4 +107,3 @@ Deprecated
* http: deprecated ``envoy.http.headermap.lazy_map_min_size``. If you are using this config knob you can revert this temporarily by setting ``envoy.reloadable_features.deprecate_global_ints`` to true but you MUST file an upstream issue to ensure this feature remains available.
* http: removing support for long-deprecated old style filter names, e.g. envoy.router, envoy.lua.
* re2: removed undocumented histograms ``re2.program_size`` and ``re2.exceeded_warn_level``.
* re2: deprecated ``re2.max_program_size.error_level`` and ``re2.max_program_size.warn_level``. If you are using these config knobs you can revert this temporarily by setting ``envoy.reloadable_features.deprecate_global_ints`` to true but you MUST file an upstream issue to ensure this feature remains available.
19 changes: 7 additions & 12 deletions source/common/runtime/runtime_features.cc
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ bool runtimeFeatureEnabled(absl::string_view feature) {

uint64_t getInteger(absl::string_view feature, uint64_t default_value) {
if (absl::StartsWith(feature, "envoy.")) {
// DO NOT ADD MORE FLAGS HERE. This function deprecated and being removed.
// DO NOT ADD MORE FLAGS HERE. This function deprecated.
if (feature == "envoy.http.headermap.lazy_map_min_size") {
return absl::GetFlag(FLAGS_envoy_headermap_lazy_map_min_size);
}
Expand Down Expand Up @@ -186,30 +186,25 @@ void maybeSetRuntimeGuard(absl::string_view name, bool value) {
absl::SetFlag(flag, value);
}

// TODO(alyssawilk) deprecate use of this
void maybeSetDeprecatedInts(absl::string_view name, uint32_t value) {
if (!absl::StartsWith(name, "envoy.") && !absl::StartsWith(name, "re2.")) {
return;
}

bool set = false;
// DO NOT ADD MORE FLAGS HERE. This function deprecated and being removed.
if (name == "envoy.http.headermap.lazy_map_min_size") {
set = true;
if (Runtime::runtimeFeatureEnabled("envoy.reloadable_features.deprecate_global_ints")) {
IS_ENVOY_BUG(absl::StrCat(
"The Envoy community is attempting to remove global integers. Given you use ", name,
" please immediately file an upstream issue to retain the functionality as it will "
"otherwise be removed following the usual deprecation cycle."));
}
absl::SetFlag(&FLAGS_envoy_headermap_lazy_map_min_size, value);
} else if (name == "re2.max_program_size.error_level") {
set = true;
absl::SetFlag(&FLAGS_re2_max_program_size_error_level, value);
} else if (name == "re2.max_program_size.warn_level") {
set = true;
absl::SetFlag(&FLAGS_re2_max_program_size_warn_level, value);
}
if (set && Runtime::runtimeFeatureEnabled("envoy.reloadable_features.deprecate_global_ints")) {
IS_ENVOY_BUG(absl::StrCat(
"The Envoy community is attempting to remove global integers. Given you use ", name,
" please immediately file an upstream issue to retain the functionality as it will "
"otherwise be removed following the usual deprecation cycle."));
}
}

std::string swapPrefix(std::string name) {
Expand Down