summaryrefslogtreecommitdiffstats
path: root/sources/hv-collector-server
diff options
context:
space:
mode:
authorPawel <pawel.kasperkiewicz@nokia.com>2020-12-17 12:17:37 +0100
committerPawel Kasperkiewicz <pawel.kasperkiewicz@nokia.com>2020-12-28 12:21:36 +0000
commitf282dc63f560fe3fc3f885097f43142bfc2f9824 (patch)
tree89c16afa2a7e6c981cadea4283f7d6892a71dc8f /sources/hv-collector-server
parent589f62651fdc96e3c76845ea2f99866f85e98d0d (diff)
Upgrade hv-ves, reactor, protobuf and sdk versions
Reactor from Dysprosium-SR11 to 2020.0.2 Protobuf from 3.6.1 to 3.14.0 SDK from 1.4.4 to 1.5.0 Issue-ID: DCAEGEN2-2537 Signed-off-by: Pawel <pawel.kasperkiewicz@nokia.com> Change-Id: Ie3fc82c67ba096efcd0c584cf3f7f35128962efe
Diffstat (limited to 'sources/hv-collector-server')
-rw-r--r--sources/hv-collector-server/pom.xml2
-rw-r--r--sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/NettyTcpServer.kt4
-rw-r--r--sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/networking.kt5
3 files changed, 6 insertions, 5 deletions
diff --git a/sources/hv-collector-server/pom.xml b/sources/hv-collector-server/pom.xml
index cce03f12..6a4c60cb 100644
--- a/sources/hv-collector-server/pom.xml
+++ b/sources/hv-collector-server/pom.xml
@@ -33,7 +33,7 @@
<parent>
<groupId>org.onap.dcaegen2.collectors.hv-ves</groupId>
<artifactId>hv-collector-sources</artifactId>
- <version>1.5.1-SNAPSHOT</version>
+ <version>1.6.0-SNAPSHOT</version>
<relativePath>..</relativePath>
</parent>
diff --git a/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/NettyTcpServer.kt b/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/NettyTcpServer.kt
index d19b7f49..7f6ad658 100644
--- a/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/NettyTcpServer.kt
+++ b/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/NettyTcpServer.kt
@@ -2,7 +2,7 @@
* ============LICENSE_START=======================================================
* dcaegen2-collectors-veshv
* ================================================================================
- * Copyright (C) 2018-2019 NOKIA
+ * Copyright (C) 2018-2020 NOKIA
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -60,7 +60,7 @@ internal class NettyTcpServer(private val serverConfiguration: ServerConfigurati
override fun start(): Mono<ServerHandle> =
Mono.defer {
TcpServer.create()
- .addressSupplier { InetSocketAddress(serverConfiguration.listenPort) }
+ .bindAddress { InetSocketAddress(serverConfiguration.listenPort) }
.configureSsl()
.handle(this::handleConnection)
.bind()
diff --git a/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/networking.kt b/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/networking.kt
index eb51cf4b..6bbe08f0 100644
--- a/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/networking.kt
+++ b/sources/hv-collector-server/src/main/kotlin/org/onap/dcae/collectors/veshv/impl/networking.kt
@@ -2,7 +2,7 @@
* ============LICENSE_START=======================================================
* dcaegen2-collectors-veshv
* ================================================================================
- * Copyright (C) 2019 NOKIA
+ * Copyright (C) 2019-2020 NOKIA
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -31,6 +31,7 @@ import reactor.netty.Connection
import reactor.netty.NettyInbound
import reactor.netty.NettyOutbound
import java.net.InetAddress
+import java.net.InetSocketAddress
import java.security.cert.X509Certificate
import javax.net.ssl.SSLSession
@@ -76,6 +77,6 @@ internal inline fun withNewClientContextFrom(nettyInbound: NettyInbound,
internal fun populateClientContextFromInbound(clientContext: ClientContext, nettyInbound: NettyInbound) =
withConnectionFrom(nettyInbound) { connection ->
- clientContext.clientAddress = Try { connection.address().address }.toOption()
+ clientContext.clientAddress = Try { (connection.address() as InetSocketAddress).address }.toOption()
clientContext.clientCert = connection.getSslSession().flatMap { it.findClientCert() }
}