aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPiotr Jaszczyk <piotr.jaszczyk@nokia.com>2019-04-05 08:45:26 +0200
committerPiotr Jaszczyk <piotr.jaszczyk@nokia.com>2019-04-09 08:44:25 +0200
commit415a3eed0d171ee33e2fd984d34c4e5950f8a931 (patch)
tree08e88d5fa8638414d68bb757f0b3d150f1b23957
parente55809c0219be0898138c436d82ceba212b92df9 (diff)
Provide enhanced component description
Change-Id: Iaed53f9acc9cdc830b2069de6d96d5f2965d9466 Issue-ID: DCAEGEN2-1394 Signed-off-by: Piotr Jaszczyk <piotr.jaszczyk@nokia.com>
-rw-r--r--dpo/data-formats/hv-ves-7.1.0.dataformatspec.json4
-rw-r--r--dpo/spec/hv-ves-collector.componentspec.json83
-rw-r--r--sources/hv-collector-utils/src/main/kotlin/org/onap/dcae/collectors/veshv/utils/server_handle.kt8
3 files changed, 90 insertions, 5 deletions
diff --git a/dpo/data-formats/hv-ves-7.1.0.dataformatspec.json b/dpo/data-formats/hv-ves-7.1.0.dataformatspec.json
index cc25e586..5aea73a4 100644
--- a/dpo/data-formats/hv-ves-7.1.0.dataformatspec.json
+++ b/dpo/data-formats/hv-ves-7.1.0.dataformatspec.json
@@ -8,8 +8,8 @@
"dataformatversion": "1.0.0",
"reference": {
"name": "VES (NF Event Streaming) Specification",
- "version": "7.1",
- "format": "proto",
+ "version": "7.1.0",
+ "format": "Protocol Buffer",
"url": "https://gerrit.onap.org/r/gitweb?p=dcaegen2.git;a=blob_plain;f=docs/sections/apis/ves-hv/VesEvent.proto;hb=HEAD"
}
} \ No newline at end of file
diff --git a/dpo/spec/hv-ves-collector.componentspec.json b/dpo/spec/hv-ves-collector.componentspec.json
index 0a020ae5..13dd64a3 100644
--- a/dpo/spec/hv-ves-collector.componentspec.json
+++ b/dpo/spec/hv-ves-collector.componentspec.json
@@ -20,7 +20,88 @@
"calls": [],
"provides": []
},
- "parameters": [],
+ "parameters": [
+ {
+ "name": "logLevel",
+ "value": "DEBUG",
+ "description": "The logging level used for collector classes",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "server.listenPort",
+ "value": 6061,
+ "description": "The container listen port",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "server.idleTimeoutSec",
+ "value": 60,
+ "description": "Maximum inactive time in seconds for client connections after which client can be disconnected",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "cbs.firstRequestDelaySec",
+ "value": 10,
+ "description": "Delay in seconds after which the first CBS request will be made",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "cbs.requestIntervalSec",
+ "value": 5,
+ "description": "Interval in seconds of re-checking the CBS configuration",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "security.sslDisable",
+ "value": true,
+ "description": "Should be set to true in order to disable client authentication and tunnel encryption",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "security.keys.keyStoreFile",
+ "value": "/etc/ves-hv/ssl/keystore.p12",
+ "description": "Points to private key store file",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "security.keys.keyStorePassword",
+ "value": "onaponap",
+ "description": "Password for the key store",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "security.keys.trustStoreFile",
+ "value": "/etc/ves-hv/ssl/truststore.p12",
+ "description": "Points to trust store file which contains trusted client certificates and/or CAs",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ },
+ {
+ "name": "security.keys.trustStorePassword",
+ "value": "onaponap",
+ "description": "Password for the trust store",
+ "sourced_at_deployment": false,
+ "policy_editable": false,
+ "designer_editable": false
+ }
+ ],
"auxilary": {
"healthcheck": {
"type": "script",
diff --git a/sources/hv-collector-utils/src/main/kotlin/org/onap/dcae/collectors/veshv/utils/server_handle.kt b/sources/hv-collector-utils/src/main/kotlin/org/onap/dcae/collectors/veshv/utils/server_handle.kt
index 728d62bb..9c0a6e1c 100644
--- a/sources/hv-collector-utils/src/main/kotlin/org/onap/dcae/collectors/veshv/utils/server_handle.kt
+++ b/sources/hv-collector-utils/src/main/kotlin/org/onap/dcae/collectors/veshv/utils/server_handle.kt
@@ -22,6 +22,7 @@ package org.onap.dcae.collectors.veshv.utils
import org.onap.dcae.collectors.veshv.utils.logging.Logger
import reactor.core.publisher.Mono
import reactor.netty.DisposableServer
+import java.time.Duration
/**
* @author Piotr Jaszczyk <piotr.jaszczyk@nokia.com>
@@ -48,14 +49,16 @@ class NettyServerHandle(private val ctx: DisposableServer,
.then(dispose())
private fun dispose(): Mono<Void> =
- Mono.create { callback ->
+ Mono.create<Int> { callback ->
logger.debug { "About to dispose NettyServer" }
ctx.dispose()
ctx.onDispose {
logger.debug { "Netty server disposed" }
- callback.success()
+ callback.success(1)
}
}
+ .delayElement(boundPortReleaseLatency)
+ .then()
override fun await(): Mono<Void> = Mono.create { callback ->
ctx.channel().closeFuture().addListener {
@@ -65,5 +68,6 @@ class NettyServerHandle(private val ctx: DisposableServer,
companion object {
private val logger = Logger(NettyServerHandle::class)
+ private val boundPortReleaseLatency = Duration.ofSeconds(1)
}
}