diff options
author | Tor Brede Vekterli <vekterli@yahooinc.com> | 2023-09-12 11:39:27 +0200 |
---|---|---|
committer | Tor Brede Vekterli <vekterli@yahooinc.com> | 2023-09-12 15:28:08 +0200 |
commit | 9653b487a5ed2c7a62b0c06c1215ea947a09ee30 (patch) | |
tree | 13990074b2accce222ed6c70c7a0e7901d65df00 /config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java | |
parent | 6ac162f1ec099f014ceee92c9afde50d2e3e8a33 (diff) |
Add feature flag for new content layer metadata features
Exposed as an integer rather than a bool to account for future
additions without needing to add more feature flags to the mix.
In particular this is because those additions are expected to
require the other additions to be present, so it's not a mix
and match situation.
Only values 0 (legacy) and 1 (operation cancellation) map to
any underlying configs at this time, though any higher number
will transparently enable cancellation. Value 2 is documented
based on its intended future semantics.
Diffstat (limited to 'config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java')
-rw-r--r-- | config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java b/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java index 31e066cdd8c..c9a25e113a6 100644 --- a/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java +++ b/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java @@ -86,6 +86,7 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea private boolean allowUserFilters = true; private List<DataplaneToken> dataplaneTokens; private boolean enableDataplaneProxy; + private int contentLayerMetadataFeatureLevel = 0; @Override public ModelContext.FeatureFlags featureFlags() { return this; } @Override public boolean multitenant() { return multitenant; } @@ -144,6 +145,7 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea @Override public boolean enableGlobalPhase() { return true; } // Enable global-phase by default for unit tests only @Override public List<DataplaneToken> dataplaneTokens() { return dataplaneTokens; } @Override public boolean enableDataplaneProxy() { return enableDataplaneProxy; } + @Override public int contentLayerMetadataFeatureLevel() { return contentLayerMetadataFeatureLevel; } public TestProperties sharedStringRepoNoReclaim(boolean sharedStringRepoNoReclaim) { this.sharedStringRepoNoReclaim = sharedStringRepoNoReclaim; @@ -379,6 +381,11 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea return this; } + public TestProperties setContentLayerMetadataFeatureLevel(int level) { + this.contentLayerMetadataFeatureLevel = level; + return this; + } + public static class Spec implements ConfigServerSpec { private final String hostName; |