diff options
author | Jakub Dudycz <jakub.dudycz@nokia.com> | 2018-09-13 09:55:02 +0200 |
---|---|---|
committer | Jakub Dudycz <jakub.dudycz@nokia.com> | 2018-09-13 09:55:02 +0200 |
commit | ba28c3baf96f93558adebaec55cfd4683455e9e9 (patch) | |
tree | 4fe1d6b2deacb95c6c42c13b43ed62fed24f2dd0 /hv-collector-core | |
parent | adf43b163120e1be161e00ea92d290b941a31d99 (diff) |
Align with configuration present in consul
Rename few configuration json keys inside collector code to match those on consul.
Change-Id: I400aebce98049118a30d7959dc6655a4da6016bf
Issue-ID: DCAEGEN2-774
Signed-off-by: Jakub Dudycz <jakub.dudycz@nokia.com>
Diffstat (limited to 'hv-collector-core')
2 files changed, 4 insertions, 4 deletions
diff --git a/hv-collector-core/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProvider.kt b/hv-collector-core/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProvider.kt index 7de28306..d8ea45d6 100644 --- a/hv-collector-core/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProvider.kt +++ b/hv-collector-core/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProvider.kt @@ -108,10 +108,10 @@ internal class ConsulConfigurationProvider(private val http: HttpAdapter, } private fun createCollectorConfiguration(configuration: JsonObject): CollectorConfiguration { - val routing = configuration.getJsonArray("routing") + val routing = configuration.getJsonArray("collector.routing") return CollectorConfiguration( - kafkaBootstrapServers = configuration.getString("kafkaBootstrapServers"), + kafkaBootstrapServers = configuration.getString("dmaap.kafkaBootstrapServers"), routing = org.onap.dcae.collectors.veshv.model.routing { for (route in routing) { val routeObj = route.asJsonObject() diff --git a/hv-collector-core/src/test/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProviderTest.kt b/hv-collector-core/src/test/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProviderTest.kt index 78858921..59224cca 100644 --- a/hv-collector-core/src/test/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProviderTest.kt +++ b/hv-collector-core/src/test/kotlin/org/onap/dcae/collectors/veshv/impl/adapters/ConsulConfigurationProviderTest.kt @@ -131,8 +131,8 @@ private fun constructConsulConfigProvider(url: String, fun constructConsulResponse(): String { val config = """{ - "kafkaBootstrapServers": "kafka:9093", - "routing": [ + "dmaap.kafkaBootstrapServers": "kafka:9093", + "collector.routing": [ { "fromDomain": 1, "toTopic": "test-topic-1" |