From 30afcb56b0c6c4529fdaf68d7b061eee44d68d16 Mon Sep 17 00:00:00 2001 From: Jakub Dudycz Date: Wed, 13 Mar 2019 18:44:31 +0100 Subject: Remove environment variables and program arguments - Move all command line program arguments to json file. - Reorganize configuration classes and the way they are passed through application - Implement HV VES configuration stream - Create concrete configuration from partial one - Modify main HV-VES server starting pipeline Change-Id: I6cf874b6904ed768e4820b8132f5f760299c929e Signed-off-by: Jakub Dudycz Issue-ID: DCAEGEN2-1340 --- development/configuration/configuration.json | 34 ++++++++++++++++++++++++++++ development/docker-compose.yml | 14 ++++-------- development/logs/.gitignore | 1 + 3 files changed, 40 insertions(+), 9 deletions(-) create mode 100644 development/configuration/configuration.json (limited to 'development') diff --git a/development/configuration/configuration.json b/development/configuration/configuration.json new file mode 100644 index 00000000..8e55cf39 --- /dev/null +++ b/development/configuration/configuration.json @@ -0,0 +1,34 @@ +{ + "logLevel": "DEBUG", + "server": { + "listenPort": 6061, + "idleTimeoutSec": 60, + "maxPayloadSizeBytes": 1048576 + }, + "cbs": { + "firstRequestDelaySec": 10, + "requestIntervalSec": 5 + }, + "security": { + "sslDisable": false, + "keys": { + "keyStoreFile": "/etc/ves-hv/ssl/server.p12", + "keyStorePassword": "onaponap", + "trustStoreFile": "/etc/ves-hv/ssl/trust.p12", + "trustStorePassword": "onaponap" + } + }, + "collector": { + "dummyMode": false, + "maxRequestSizeBytes": 1048576, + "kafkaServers": [ + "message-router-kafka:9092" + ], + "routing": [ + { + "fromDomain": "perf3gpp", + "toTopic": "HV_VES_PERF3GPP" + } + ] + } +} \ No newline at end of file diff --git a/development/docker-compose.yml b/development/docker-compose.yml index abd55ab9..85500cbb 100644 --- a/development/docker-compose.yml +++ b/development/docker-compose.yml @@ -73,15 +73,9 @@ services: ports: - "6060:6060" - "6061:6061/tcp" - command: ["--listen-port", "6061", - "--health-check-api-port", "6060", - "--kafka-bootstrap-servers", "message-router-kafka:9092", - "--key-store-password", "onaponap", - "--trust-store-password", "onaponap", - "--first-request-delay", "5", - "--log-level", "DEBUG"] + command: ["--configuration-file /etc/ves-hv/configuration/configuration.json"] environment: - JAVA_OPTS: "-Dio.netty.leakDetection.level=paranoid -Dlogback.configurationFile=/etc/ONAP/dcae-hv-ves-collector/logback.xml" + JAVA_OPTS: "-Dio.netty.leakDetection.level=paranoid -Dlogback.configurationFile=/etc/ONAP/dcae-hv-ves-collector/logback.xml" CONSUL_HOST: "consul-server" CONFIG_BINDING_SERVICE: "cbs" HOSTNAME: "dcae-hv-ves-collector" @@ -95,7 +89,8 @@ services: - message-router-kafka - config-binding-service volumes: - - ./ssl/:/etc/ves-hv/ + - ./configuration/:/etc/ves-hv/configuration/ + - ./ssl/:/etc/ves-hv/ssl/ - ./logs:/var/log/ONAP/dcae-hv-ves-collector @@ -139,6 +134,7 @@ services: # # Monitoring # + prometheus: image: prom/prometheus ports: diff --git a/development/logs/.gitignore b/development/logs/.gitignore index f935021a..1287e9bd 100644 --- a/development/logs/.gitignore +++ b/development/logs/.gitignore @@ -1 +1,2 @@ +** !.gitignore -- cgit 1.2.3-korg