diff options
author | Filip Krzywka <filip.krzywka@nokia.com> | 2019-03-26 13:14:09 +0100 |
---|---|---|
committer | Filip Krzywka <filip.krzywka@nokia.com> | 2019-03-27 08:07:15 +0100 |
commit | 8e95c1191af4ce0f2e0d87f62657b30d66ddc397 (patch) | |
tree | 0090fdd97ddbbaf3aa1c0fbef0c5da778fd675a1 /sources/hv-collector-configuration | |
parent | 58ae1a831a6fe85abda8c4d866e5170c70499ac1 (diff) |
Remove dummyMode configuration option
As it's not really used by anyone and it's functionality does not bring
much value
Change-Id: I99b07e484a8494a036f1f1b07e21666e044edbdb
Issue-ID: DCAEGEN2-1347
Signed-off-by: Filip Krzywka <filip.krzywka@nokia.com>
Diffstat (limited to 'sources/hv-collector-configuration')
6 files changed, 2 insertions, 10 deletions
diff --git a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/api/model/Configuration.kt b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/api/model/Configuration.kt index 566f2c08..3375821e 100644 --- a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/api/model/Configuration.kt +++ b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/api/model/Configuration.kt @@ -49,6 +49,5 @@ data class CbsConfiguration( data class CollectorConfiguration( val maxRequestSizeBytes: Int, val kafkaServers: String, - val routing: Routing, - val dummyMode: Boolean = false + val routing: Routing ) diff --git a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidator.kt b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidator.kt index 90be3dbd..330ec7c1 100644 --- a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidator.kt +++ b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidator.kt @@ -97,8 +97,7 @@ internal class ConfigurationValidator { CollectorConfiguration( it.maxRequestSizeBytes.bind(), toKafkaServersString(it.kafkaServers.bind()), - it.routing.bind(), - it.dummyMode.bind() + it.routing.bind() ) } diff --git a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/PartialConfiguration.kt b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/PartialConfiguration.kt index 3e6df3e0..3cedd6b5 100644 --- a/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/PartialConfiguration.kt +++ b/sources/hv-collector-configuration/src/main/kotlin/org/onap/dcae/collectors/veshv/config/impl/PartialConfiguration.kt @@ -52,7 +52,6 @@ internal data class PartialCbsConfig( internal data class PartialSecurityConfig(val keys: Option<SecurityKeys> = None) internal data class PartialCollectorConfig( - val dummyMode: Option<Boolean> = None, val maxRequestSizeBytes: Option<Int> = None, val kafkaServers: Option<List<InetSocketAddress>> = None, val routing: Option<Routing> = None diff --git a/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidatorTest.kt b/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidatorTest.kt index beb5df61..696f42a2 100644 --- a/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidatorTest.kt +++ b/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/ConfigurationValidatorTest.kt @@ -64,7 +64,6 @@ internal object ConfigurationValidatorTest : Spek({ Some(mock()) )), Some(PartialCollectorConfig( - Some(true), Some(4), Some(emptyList()), Some(routing { }.build()) @@ -105,7 +104,6 @@ internal object ConfigurationValidatorTest : Spek({ securityKeys )), Some(PartialCollectorConfig( - Some(true), Some(4), Some(emptyList()), Some(routing) @@ -156,7 +154,6 @@ internal object ConfigurationValidatorTest : Spek({ securityKeys )), Some(PartialCollectorConfig( - Some(true), Some(4), Some(emptyList()), Some(routing) diff --git a/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/FileConfigurationReaderTest.kt b/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/FileConfigurationReaderTest.kt index 8267e304..bbf259c7 100644 --- a/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/FileConfigurationReaderTest.kt +++ b/sources/hv-collector-configuration/src/test/kotlin/org/onap/dcae/collectors/veshv/config/impl/FileConfigurationReaderTest.kt @@ -145,7 +145,6 @@ internal object FileConfigurationReaderTest : Spek({ assertThat(config.collector.nonEmpty()).isTrue() val collector = config.collector.orNull() as PartialCollectorConfig collector.run { - assertThat(dummyMode).isEqualTo(Some(false)) assertThat(maxRequestSizeBytes).isEqualTo(Some(512000)) assertThat(kafkaServers.nonEmpty()).isTrue() assertThat(routing.nonEmpty()).isTrue() diff --git a/sources/hv-collector-configuration/src/test/resources/sampleConfig.json b/sources/hv-collector-configuration/src/test/resources/sampleConfig.json index b49085e8..5ae9fc02 100644 --- a/sources/hv-collector-configuration/src/test/resources/sampleConfig.json +++ b/sources/hv-collector-configuration/src/test/resources/sampleConfig.json @@ -20,7 +20,6 @@ } }, "collector": { - "dummyMode": false, "maxRequestSizeBytes": 512000, "kafkaServers": [ "192.168.255.1:5005", |