diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2022-01-12 16:47:31 +0100 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2022-01-12 16:47:50 +0100 |
commit | ed4938a382461c93062482fc29e76b472688165f (patch) | |
tree | 42ef95b644901c0062ff37b797f7fe29a59f4491 /config-model | |
parent | 835ace28e028fc09b07974e68e0c92afba6c9ed5 (diff) |
GC featureflag control of max size of transaction log
Diffstat (limited to 'config-model')
-rw-r--r-- | config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java | 7 | ||||
-rw-r--r-- | config-model/src/test/java/com/yahoo/vespa/model/content/ContentClusterTest.java | 16 |
2 files changed, 5 insertions, 18 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 2dc91ab1b1f..4260ceb7ec5 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 @@ -76,7 +76,6 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea private List<String> zoneDnsSuffixes = List.of(); private int maxCompactBuffers = 1; private boolean failDeploymentWithInvalidJvmOptions = false; - private double tlsSizeFraction = 0.02; private String persistenceAsyncThrottling = "UNLIMITED"; @Override public ModelContext.FeatureFlags featureFlags() { return this; } @@ -134,7 +133,6 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea @Override public List<String> zoneDnsSuffixes() { return zoneDnsSuffixes; } @Override public int maxCompactBuffers() { return maxCompactBuffers; } @Override public boolean failDeploymentWithInvalidJvmOptions() { return failDeploymentWithInvalidJvmOptions; } - @Override public double tlsSizeFraction() { return tlsSizeFraction; } @Override public String persistenceAsyncThrottling() { return persistenceAsyncThrottling; } public TestProperties maxUnCommittedMemory(int maxUnCommittedMemory) { @@ -353,11 +351,6 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea return this; } - public TestProperties tlsSizeFraction(double tlsSizeFraction) { - this.tlsSizeFraction = tlsSizeFraction; - return this; - } - public TestProperties setPersistenceAsyncThrottling(String type) { this.persistenceAsyncThrottling = type; return this; diff --git a/config-model/src/test/java/com/yahoo/vespa/model/content/ContentClusterTest.java b/config-model/src/test/java/com/yahoo/vespa/model/content/ContentClusterTest.java index 4295f0aa6ec..0c1c2c74dd1 100644 --- a/config-model/src/test/java/com/yahoo/vespa/model/content/ContentClusterTest.java +++ b/config-model/src/test/java/com/yahoo/vespa/model/content/ContentClusterTest.java @@ -45,7 +45,6 @@ import java.util.Collections; import java.util.List; import java.util.Map; import java.util.Optional; -import java.util.OptionalDouble; import java.util.OptionalInt; import static org.junit.Assert.assertEquals; @@ -1046,11 +1045,9 @@ public class ContentClusterTest extends ContentBaseTest { assertEquals(7, resolveMaxCompactBuffers(OptionalInt.of(7))); } - private long resolveMaxTLSSize(OptionalDouble tlsSizeFraction, Optional<Flavor> flavor) throws Exception { + private long resolveMaxTLSSize(Optional<Flavor> flavor) throws Exception { TestProperties testProperties = new TestProperties(); - if (tlsSizeFraction.isPresent()) { - testProperties.tlsSizeFraction(tlsSizeFraction.getAsDouble()); - } + ContentCluster cc = createOneNodeCluster(testProperties, flavor); ProtonConfig.Builder protonBuilder = new ProtonConfig.Builder(); cc.getSearch().getSearchNodes().get(0).getConfig(protonBuilder); @@ -1058,13 +1055,10 @@ public class ContentClusterTest extends ContentBaseTest { return protonConfig.flush().memory().maxtlssize(); } @Test - public void default_max_tls_size_controlled_by_properties() throws Exception { + public void verifyt_max_tls_size() throws Exception { var flavor = new Flavor(new FlavorsConfig.Flavor(new FlavorsConfig.Flavor.Builder().name("test").minDiskAvailableGb(100))); - assertEquals(21474836480L, resolveMaxTLSSize(OptionalDouble.empty(), Optional.empty())); - assertEquals(21474836480L, resolveMaxTLSSize(OptionalDouble.of(0.02), Optional.empty())); - assertEquals(2147483648L, resolveMaxTLSSize(OptionalDouble.empty(), Optional.of(flavor))); - assertEquals(2147483648L, resolveMaxTLSSize(OptionalDouble.of(0.02), Optional.of(flavor))); - assertEquals(3221225472L, resolveMaxTLSSize(OptionalDouble.of(0.03), Optional.of(flavor))); + assertEquals(21474836480L, resolveMaxTLSSize(Optional.empty())); + assertEquals(2147483648L, resolveMaxTLSSize(Optional.of(flavor))); } void assertZookeeperServerImplementation(String expectedClassName, |