Merge "NONRTRIC - Implement DMaaP mediator producer service in Java"
authorHenrik Andersson <henrik.b.andersson@est.tech>
Wed, 24 Nov 2021 13:18:53 +0000 (13:18 +0000)
committerGerrit Code Review <gerrit@o-ran-sc.org>
Wed, 24 Nov 2021 13:18:53 +0000 (13:18 +0000)
93 files changed:
docs/api-docs.rst
docs/conf.py
docs/developer-guide.rst
docs/overview.rst
enrichment-coordinator-service [new symlink]
information-coordinator-service/.gitignore [moved from enrichment-coordinator-service/.gitignore with 100% similarity]
information-coordinator-service/Dockerfile [moved from enrichment-coordinator-service/Dockerfile with 53% similarity]
information-coordinator-service/api/ics-api.json [moved from enrichment-coordinator-service/api/ecs-api.json with 100% similarity]
information-coordinator-service/api/ics-api.yaml [moved from enrichment-coordinator-service/api/ecs-api.yaml with 100% similarity]
information-coordinator-service/config/README [moved from enrichment-coordinator-service/config/README with 100% similarity]
information-coordinator-service/config/application.yaml [moved from enrichment-coordinator-service/config/application.yaml with 81% similarity]
information-coordinator-service/config/keystore.jks [moved from enrichment-coordinator-service/config/keystore.jks with 100% similarity]
information-coordinator-service/config/truststore.jks [moved from enrichment-coordinator-service/config/truststore.jks with 100% similarity]
information-coordinator-service/eclipse-formatter.xml [moved from enrichment-coordinator-service/eclipse-formatter.xml with 100% similarity]
information-coordinator-service/pom.xml [moved from enrichment-coordinator-service/pom.xml with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/Application.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/Application.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/BeanFactory.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/BeanFactory.java with 93% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/SwaggerConfig.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/SwaggerConfig.java with 94% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/clients/AsyncRestClient.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClient.java with 98% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/clients/AsyncRestClientFactory.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClientFactory.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/configuration/ApplicationConfig.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/ApplicationConfig.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/configuration/WebClientConfig.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/WebClientConfig.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/ErrorResponse.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/ErrorResponse.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/StatusController.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/StatusController.java with 95% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/VoidResponse.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/VoidResponse.java with 95% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/a1e/A1eCallbacks.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/a1e/A1eCallbacks.java with 88% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/a1e/A1eConsts.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/a1e/A1eConsts.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/a1e/A1eController.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/a1e/A1eController.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/a1e/A1eEiJobInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/a1e/A1eEiJobInfo.java with 98% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/a1e/A1eEiJobStatus.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/a1e/A1eEiJobStatus.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/a1e/A1eEiTypeInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/a1e/A1eEiTypeInfo.java with 95% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerCallbacks.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerCallbacks.java with 88% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerConsts.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerConsts.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerController.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerController.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerInfoTypeInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerInfoTypeInfo.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerJobInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerJobInfo.java with 98% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerJobStatus.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerJobStatus.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerTypeRegistrationInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerTypeRegistrationInfo.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1consumer/ConsumerTypeSubscriptionInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1consumer/ConsumerTypeSubscriptionInfo.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1producer/ProducerCallbacks.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1producer/ProducerCallbacks.java with 91% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1producer/ProducerConsts.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1producer/ProducerConsts.java with 95% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1producer/ProducerController.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1producer/ProducerController.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1producer/ProducerInfoTypeInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1producer/ProducerInfoTypeInfo.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1producer/ProducerJobInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1producer/ProducerJobInfo.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1producer/ProducerRegistrationInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1producer/ProducerRegistrationInfo.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/controllers/r1producer/ProducerStatusInfo.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/r1producer/ProducerStatusInfo.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/exceptions/ServiceException.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/exceptions/ServiceException.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/InfoJob.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/InfoJob.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/InfoJobs.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/InfoJobs.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/InfoProducer.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/InfoProducer.java with 98% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/InfoProducers.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/InfoProducers.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/InfoType.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/InfoType.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/InfoTypeSubscriptions.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/InfoTypeSubscriptions.java with 98% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/InfoTypes.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/InfoTypes.java with 96% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/repository/MultiMap.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/repository/MultiMap.java with 97% similarity]
information-coordinator-service/src/main/java/org/oransc/ics/tasks/ProducerSupervision.java [moved from enrichment-coordinator-service/src/main/java/org/oransc/enrichment/tasks/ProducerSupervision.java with 90% similarity]
information-coordinator-service/src/test/java/org/oransc/ics/ApplicationTest.java [moved from enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java with 95% similarity]
information-coordinator-service/src/test/java/org/oransc/ics/MockEnrichmentService.java [moved from enrichment-coordinator-service/src/test/java/org/oransc/enrichment/MockEnrichmentService.java with 98% similarity]
information-coordinator-service/src/test/java/org/oransc/ics/clients/AsyncRestClientTest.java [moved from enrichment-coordinator-service/src/test/java/org/oransc/enrichment/clients/AsyncRestClientTest.java with 99% similarity]
information-coordinator-service/src/test/java/org/oransc/ics/controller/ConsumerSimulatorController.java [moved from enrichment-coordinator-service/src/test/java/org/oransc/enrichment/controller/ConsumerSimulatorController.java with 93% similarity]
information-coordinator-service/src/test/java/org/oransc/ics/controller/ProducerSimulatorController.java [moved from enrichment-coordinator-service/src/test/java/org/oransc/enrichment/controller/ProducerSimulatorController.java with 96% similarity]
pom.xml
test/common/cr_api_functions.sh
test/common/genstat.sh
test/common/mr_api_functions.sh
test/common/pa_api_functions.sh
test/common/ricsim_api_functions.sh
test/common/test_env-onap-guilin.sh
test/common/test_env-onap-honolulu.sh
test/common/test_env-onap-istanbul.sh
test/common/test_env-oran-cherry.sh
test/common/test_env-oran-d-release.sh
test/common/test_env-oran-e-release.sh
test/common/testcase_common.sh
test/simulator-group/consul_cbs/docker-compose.yml
test/simulator-group/control_panel/docker-compose.yml
test/simulator-group/cr/docker-compose.yml
test/simulator-group/dmaapadp/docker-compose.yml
test/simulator-group/dmaapmed/docker-compose.yml
test/simulator-group/dmaapmr/app.yaml
test/simulator-group/dmaapmr/docker-compose.yml
test/simulator-group/dmaapmr/svc.yaml
test/simulator-group/ecs/docker-compose.yml
test/simulator-group/httpproxy/docker-compose.yml
test/simulator-group/kubeproxy/docker-compose.yml
test/simulator-group/mrstub/docker-compose.yml
test/simulator-group/ngw/docker-compose.yml
test/simulator-group/policy_agent/docker-compose.yml
test/simulator-group/prodstub/docker-compose.yml
test/simulator-group/rapp_catalogue/docker-compose.yml
test/simulator-group/ric/docker-compose.yml
test/simulator-group/sdnc/docker-compose-2.yml
test/simulator-group/sdnc/docker-compose.yml

index ef234a5..51d18ee 100644 (file)
@@ -20,7 +20,7 @@ Here we describe the APIs to access the Non-RT RIC functions.
 The core Non-RT RIC consists of several parts, with available APIs described in the sections below:
 
 * The A1 Policy Management Service
-* The Enrichment Coordinator Service
+* The Information Coordinator Service
 * The Non-RT-RIC App Catalogue
 * K8S Helm Chart LCM Manager (Initial) **<ToDo>**
 
@@ -29,10 +29,10 @@ A1 Policy Management Service
 
 For information about the A1 Policy Management Service that is implemented in ONAP, see `ONAP docs <https://docs.onap.org/projects/onap-ccsdk-oran/en/latest/index.html>`_ and `wiki <https://wiki.onap.org/pages/viewpage.action?pageId=84672221>`_.
 
-Enrichment Coordinator Service
-==============================
+Information Coordinator Service
+===============================
 
-See `A1 Enrichment Information Coordination Service API <./ecs-api.html>`_ for full details of the API.
+See `A1 Information Information Coordination Service API <./ics-api.html>`_ for full details of the API.
 
 The API is also described in Swagger-JSON and YAML:
 
@@ -40,7 +40,7 @@ The API is also described in Swagger-JSON and YAML:
    :header: "API name", "|swagger-icon|", "|yaml-icon|"
    :widths: 10,5,5
 
-   "A1 Enrichment Information Coordination Service API", ":download:`link <../enrichment-coordinator-service/api/ecs-api.json>`", ":download:`link <../enrichment-coordinator-service/api/ecs-api.yaml>`"
+   "A1 Enrichment Information Coordination Service API", ":download:`link <../information-coordinator-service/api/ics-api.json>`", ":download:`link <../information-coordinator-service/api/ics-api.yaml>`"
 
 Non-RT-RIC App Catalogue (Initial)
 ==================================
index 85721c6..ff5fcc9 100644 (file)
@@ -24,7 +24,7 @@ redoc = [
             {
                 'name': 'ECS API',
                 'page': 'ecs-api',
-                'spec': '../enrichment-coordinator-service/api/ecs-api.json',
+                'spec': '../information-coordinator-service/api/ics-api.json',
                 'embed': True,
             }
         ]
index 43ac2d1..e0cb080 100644 (file)
@@ -15,21 +15,21 @@ A1 Policy Management Service & SDNC/A1 Controller & A1 Adapter
 The A1 Policy Management Service is implemented in ONAP. For documentation see `ONAP CCSDK documentation <https://docs.onap.org/projects/onap-ccsdk-oran/en/latest/index.html>`_
 and `wiki <https://wiki.onap.org/pages/viewpage.action?pageId=84672221>`_.
 
-Enrichment Coordinator Service
-------------------------------
-The Enrichment Coordinator Service is a Java 11 web application built using the Spring Framework. Using Spring Boot
+Information Coordinator Service
+-------------------------------
+The Information Coordinator Service is a Java 11 web application built using the Spring Framework. Using Spring Boot
 dependencies, it runs as a standalone application.
 
 Its main functionality is to act as a data subscription broker and to decouple data producer from data consumers.
 
-See the ./config/README file in the *enrichment-coordinator-service* directory Gerrit repo on how to create and setup
+See the ./config/README file in the *information-coordinator-service* directory Gerrit repo on how to create and setup
 the certificates and private keys needed for HTTPS.
 
 Start standalone
 ++++++++++++++++
 
-The project uses Maven. To start the Enrichment Coordinator Service as a freestanding application, run the following
-command in the *enrichment-coordinator-service* directory:
+The project uses Maven. To start the Information Coordinator Service as a freestanding application, run the following
+command in the *information-coordinator-service* directory:
 
     +-----------------------------+
     | mvn spring-boot:run         |
@@ -38,7 +38,7 @@ command in the *enrichment-coordinator-service* directory:
 Start in Docker
 +++++++++++++++
 
-To build and deploy the Enrichment Coordinator Service, go to the "enrichment-coordinator-service" folder and run the
+To build and deploy the Information Coordinator Service, go to the "information-coordinator-service" folder and run the
 following command:
 
     +-----------------------------+
@@ -48,7 +48,7 @@ following command:
 Then start the container by running the following command:
 
     +--------------------------------------------------------------------+
-    | docker run nonrtric-enrichment-coordinator-service                 |
+    | docker run nonrtric-information-coordinator-service                |
     +--------------------------------------------------------------------+
 
 Initial Non-RT-RIC App Catalogue
index 8645a18..e816975 100644 (file)
@@ -24,7 +24,7 @@ These are the components that make up the Non-RT-RIC:
 * Non-RT-RIC Control Panel / Dashboard
 * A1 Policy Management Service (developed in ONAP)
 * A1/SDNC Controller & A1 Adapter (Controller plugin)
-* Enrichment Information Coordinator
+* Information Coordinator Service
 * Non-RT-RIC (Spring Cloud) Service Gateway
 * Non-RT-RIC (Kong) Service Exposure Prototyping
 * Initial Non-RT-RIC App Catalogue
@@ -40,7 +40,7 @@ Graphical user interface
 * View and Manage A1 policies in the RAN (near-RT-RICs)
 * Interacts with the Policy agent’s NBI (REST API)
 * Graphical A1 policy creation/editing is model-driven, based on policy type’s JSON schema
-* View and manage producers and jobs for the Enrichment coordinator service
+* View and manage producers and jobs for the Information coordinator service
 * Configure A1 Policy Management Service (e.g. add/remove near-rt-rics)
 * Interacts with the A1-PolicyManagementService & A1-EI-Coordinator (REST NBIs) via Service Exposure gateway
      
@@ -90,8 +90,8 @@ Mediation point for A1 interface termination in SMO/NONRTRIC
 
 See also: `A1 Adapter/Controller Functions in ONAP <https://wiki.onap.org/pages/viewpage.action?pageId=84672221>`_  
   
-Enrichment Information Job Coordination Service
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+Information Job Coordination Service
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 Coordinate/Register A1-EI Types, Producers, Consumers, and Jobs.
 
@@ -106,14 +106,14 @@ Coordinate/Register A1-EI Types, Producers, Consumers, and Jobs.
 * Query status of A1-EI jobs
 * Monitors all near-RT-RICs and recovers from inconsistencies
 * After EI-type/Producer/Consumer/Job is successfully registered delivery/flow can happen directly between A1-EI Producers (in SMO/NONRTRIC domain) and A1-EI consumers (near-RT-RICs in RAN domain)
-* *Being extended to coordinate non-A1 Enrichment Information exchange between NONRTRIC Apps*
+* *Being extended to coordinate non-A1 Information exchange between NONRTRIC Apps*
 
 Non-RT-RIC (Spring Cloud) Service Gateway
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 Support Apps to use A1 Services 
 
 * `Spring Cloud Gateway <https://cloud.spring.io/spring-cloud-gateway>`_ provides the library to build a basic API gateway
-* Exposes A1 Policy Management Service & Enrichment Coordinator Service.  
+* Exposes A1 Policy Management Service & Information Coordinator Service.  
 * Additional predicates can be added in code or preferably in the Gateway yaml configuration.
 
 Implementation:
@@ -162,7 +162,7 @@ A1 Interface / Near-RT-RIC Simulator
 Stateful A1 test stub.
 
 * Used to create multiple stateful A1 providers (simulated near-rt-rics)
-* Supports A1-Policy and A1-EnrichmentInformation
+* Supports A1-Policy and A1-Enrichment Information
 * Swagger-based northbound interface, so easy to change the A1 profile exposed (e.g. A1 version, A1 Policy Types, A1-E1 consumers, etc)
 * All A1-AP versions supported
 
diff --git a/enrichment-coordinator-service b/enrichment-coordinator-service
new file mode 120000 (symlink)
index 0000000..750df39
--- /dev/null
@@ -0,0 +1 @@
+information-coordinator-service
\ No newline at end of file
similarity index 53%
rename from enrichment-coordinator-service/Dockerfile
rename to information-coordinator-service/Dockerfile
index 744a237..e9d179d 100644 (file)
@@ -21,23 +21,23 @@ FROM openjdk:11-jre-slim
 
 ARG JAR
 
-WORKDIR /opt/app/enrichment-coordinator-service
-RUN mkdir -p /var/log/enrichment-coordinator-service
-RUN mkdir -p /opt/app/enrichment-coordinator-service/etc/cert/
-RUN mkdir -p /var/enrichment-coordinator-service
-RUN chmod -R 777 /var/enrichment-coordinator-service
+WORKDIR /opt/app/information-coordinator-service
+RUN mkdir -p /var/log/information-coordinator-service
+RUN mkdir -p /opt/app/information-coordinator-service/etc/cert/
+RUN mkdir -p /var/information-coordinator-service
+RUN chmod -R 777 /var/information-coordinator-service
 
 EXPOSE 8083 8434
 
-ADD /config/application.yaml /opt/app/enrichment-coordinator-service/config/application.yaml
-ADD target/${JAR} /opt/app/enrichment-coordinator-service/enrichment-coordinator-service.jar
-ADD /config/keystore.jks /opt/app/enrichment-coordinator-service/etc/cert/keystore.jks
-ADD /config/truststore.jks /opt/app/enrichment-coordinator-service/etc/cert/truststore.jks
+ADD /config/application.yaml /opt/app/information-coordinator-service/config/application.yaml
+ADD target/${JAR} /opt/app/information-coordinator-service/information-coordinator-service.jar
+ADD /config/keystore.jks /opt/app/information-coordinator-service/etc/cert/keystore.jks
+ADD /config/truststore.jks /opt/app/information-coordinator-service/etc/cert/truststore.jks
 
 
-RUN chmod -R 777 /opt/app/enrichment-coordinator-service/config/
+RUN chmod -R 777 /opt/app/information-coordinator-service/config/
 
-CMD ["java", "-jar", "/opt/app/enrichment-coordinator-service/enrichment-coordinator-service.jar"]
+CMD ["java", "-jar", "/opt/app/information-coordinator-service/information-coordinator-service.jar"]
 
 
 
@@ -19,9 +19,9 @@ logging:
     org.springframework: ERROR
     org.springframework.data: ERROR
     org.springframework.web.reactive.function.client.ExchangeFunctions: ERROR
-    org.oransc.enrichment: INFO
+    org.oransc.ics: INFO
   file:
-    name: /var/log/enrichment-coordinator-service/application.log
+    name: /var/log/information-coordinator-service/application.log
 server:
    # Configuration of the HTTP/REST server. The parameters are defined and handeled by the springboot framework.
    # See springboot documentation.
@@ -30,7 +30,7 @@ server:
    ssl:
       key-store-type: JKS
       key-store-password: policy_agent
-      key-store: /opt/app/enrichment-coordinator-service/etc/cert/keystore.jks
+      key-store: /opt/app/information-coordinator-service/etc/cert/keystore.jks
       key-password: policy_agent
       key-alias: policy_agent
 app:
@@ -40,10 +40,10 @@ app:
     # Note that the same keystore as for the server is used.
     trust-store-used: false
     trust-store-password: policy_agent
-    trust-store: /opt/app/enrichment-coordinator-service/etc/cert/truststore.jks
+    trust-store: /opt/app/information-coordinator-service/etc/cert/truststore.jks
     # Configuration of usage of HTTP Proxy for the southbound accesses.
     # The HTTP proxy (if configured) will only be used for accessing NearRT RIC:s
     http.proxy-host:
     http.proxy-port: 0
-  vardata-directory: /var/enrichment-coordinator-service
+  vardata-directory: /var/information-coordinator-service
 
similarity index 96%
rename from enrichment-coordinator-service/pom.xml
rename to information-coordinator-service/pom.xml
index 4edf4d4..2de2bf2 100644 (file)
@@ -30,7 +30,7 @@
         <relativePath />
     </parent>
     <groupId>org.o-ran-sc.nonrtric</groupId>
-    <artifactId>enrichment-coordinator-service</artifactId>
+    <artifactId>information-coordinator-service</artifactId>
     <version>1.2.0-SNAPSHOT</version>
     <licenses>
         <license>
                             <goal>generate</goal>
                         </goals>
                         <configuration>
-                            <inputSpec>${project.basedir}/api/ecs-api.json</inputSpec>
+                            <inputSpec>${project.basedir}/api/ics-api.json</inputSpec>
                             <language>openapi-yaml</language>
                             <output>${project.basedir}/api</output>
                             <configOptions>
-                                <outputFile>ecs-api.yaml</outputFile>
+                                <outputFile>ics-api.yaml</outputFile>
                             </configOptions>
                         </configuration>
                     </execution>
                 <inherited>false</inherited>
                 <executions>
                     <execution>
-                        <id>generate-enrichment-coordinator-service-image</id>
+                        <id>generate-information-coordinator-service-image</id>
                         <phase>package</phase>
                         <goals>
                             <goal>build</goal>
                             <pullRegistry>${env.CONTAINER_PULL_REGISTRY}</pullRegistry>
                             <images>
                                 <image>
-                                    <name>o-ran-sc/nonrtric-enrichment-coordinator-service:${project.version}</name>
+                                    <name>o-ran-sc/nonrtric-information-coordinator-service:${project.version}</name>
                                     <build>
                                         <cleanup>try</cleanup>
                                         <contextDir>${basedir}</contextDir>
                         </configuration>
                     </execution>
                     <execution>
-                        <id>push-enrichment-coordinator-service-image</id>
+                        <id>push-information-coordinator-service-image</id>
                         <goals>
                             <goal>build</goal>
                             <goal>push</goal>
                             <pushRegistry>${env.CONTAINER_PUSH_REGISTRY}</pushRegistry>
                             <images>
                                 <image>
-                                    <name>o-ran-sc/nonrtric-enrichment-coordinator-service:${project.version}</name>
+                                    <name>o-ran-sc/nonrtric-information-coordinator-service:${project.version}</name>
                                     <build>
                                         <contextDir>${basedir}</contextDir>
                                         <dockerFile>Dockerfile</dockerFile>
         <system>JIRA</system>
         <url>https://jira.o-ran-sc.org/</url>
     </issueManagement>
-</project>
+</project>
\ No newline at end of file
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment;
+package org.oransc.ics;
 
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment;
+package org.oransc.ics;
 
 import com.fasterxml.jackson.databind.ObjectMapper;
 
 import java.lang.invoke.MethodHandles;
 
 import org.apache.catalina.connector.Connector;
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.controllers.r1producer.ProducerCallbacks;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoTypes;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.controllers.r1producer.ProducerCallbacks;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoTypes;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Value;
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment;
+package org.oransc.ics;
 
 import io.swagger.v3.oas.annotations.OpenAPIDefinition;
 import io.swagger.v3.oas.annotations.info.Info;
 import io.swagger.v3.oas.annotations.info.License;
 import io.swagger.v3.oas.annotations.tags.Tag;
 
-import org.oransc.enrichment.controllers.StatusController;
-import org.oransc.enrichment.controllers.a1e.A1eConsts;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerConsts;
-import org.oransc.enrichment.controllers.r1producer.ProducerConsts;
+import org.oransc.ics.controllers.StatusController;
+import org.oransc.ics.controllers.a1e.A1eConsts;
+import org.oransc.ics.controllers.r1consumer.ConsumerConsts;
+import org.oransc.ics.controllers.r1producer.ProducerConsts;
 
 /**
  * Swagger configuration class that uses swagger documentation type and scans
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.clients;
+package org.oransc.ics.clients;
 
 import io.netty.channel.ChannelOption;
 import io.netty.handler.ssl.SslContext;
@@ -28,7 +28,7 @@ import io.netty.handler.timeout.WriteTimeoutHandler;
 import java.lang.invoke.MethodHandles;
 import java.util.concurrent.atomic.AtomicInteger;
 
-import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
+import org.oransc.ics.configuration.WebClientConfig.HttpProxyConfig;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.http.MediaType;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.clients;
+package org.oransc.ics.clients;
 
 import io.netty.handler.ssl.SslContext;
 import io.netty.handler.ssl.SslContextBuilder;
@@ -41,8 +41,8 @@ import java.util.stream.Collectors;
 
 import javax.net.ssl.KeyManagerFactory;
 
-import org.oransc.enrichment.configuration.WebClientConfig;
-import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
+import org.oransc.ics.configuration.WebClientConfig;
+import org.oransc.ics.configuration.WebClientConfig.HttpProxyConfig;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.util.ResourceUtils;
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.configuration;
+package org.oransc.ics.configuration;
 
 import lombok.Getter;
 
-import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
+import org.oransc.ics.configuration.WebClientConfig.HttpProxyConfig;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Value;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers;
+package org.oransc.ics.controllers;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
@@ -26,7 +26,7 @@ import com.google.gson.annotations.SerializedName;
 
 import io.swagger.v3.oas.annotations.media.Schema;
 
-import org.oransc.enrichment.exceptions.ServiceException;
+import org.oransc.ics.exceptions.ServiceException;
 import org.springframework.http.HttpHeaders;
 import org.springframework.http.HttpStatus;
 import org.springframework.http.MediaType;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers;
+package org.oransc.ics.controllers;
 
 import com.fasterxml.jackson.annotation.JsonProperty;
 import com.google.gson.annotations.SerializedName;
@@ -31,9 +31,9 @@ import io.swagger.v3.oas.annotations.responses.ApiResponses;
 import io.swagger.v3.oas.annotations.tags.Tag;
 
 import org.immutables.gson.Gson;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducers;
-import org.oransc.enrichment.repository.InfoTypes;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducers;
+import org.oransc.ics.repository.InfoTypes;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.http.HttpStatus;
 import org.springframework.http.MediaType;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers.a1e;
+package org.oransc.ics.controllers.a1e;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
@@ -26,13 +26,13 @@ import com.google.gson.GsonBuilder;
 import java.lang.invoke.MethodHandles;
 import java.util.Collection;
 
-import org.oransc.enrichment.clients.AsyncRestClient;
-import org.oransc.enrichment.clients.AsyncRestClientFactory;
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.repository.InfoJob;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducers;
-import org.oransc.enrichment.repository.InfoType;
+import org.oransc.ics.clients.AsyncRestClient;
+import org.oransc.ics.clients.AsyncRestClientFactory;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.repository.InfoJob;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducers;
+import org.oransc.ics.repository.InfoType;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers.a1e;
+package org.oransc.ics.controllers.a1e;
 
 import com.fasterxml.jackson.databind.ObjectMapper;
 import com.google.gson.Gson;
@@ -40,16 +40,16 @@ import java.util.ArrayList;
 import java.util.List;
 
 import org.json.JSONObject;
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.controllers.ErrorResponse;
-import org.oransc.enrichment.controllers.VoidResponse;
-import org.oransc.enrichment.controllers.r1producer.ProducerCallbacks;
-import org.oransc.enrichment.exceptions.ServiceException;
-import org.oransc.enrichment.repository.InfoJob;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducers;
-import org.oransc.enrichment.repository.InfoType;
-import org.oransc.enrichment.repository.InfoTypes;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.controllers.ErrorResponse;
+import org.oransc.ics.controllers.VoidResponse;
+import org.oransc.ics.controllers.r1producer.ProducerCallbacks;
+import org.oransc.ics.exceptions.ServiceException;
+import org.oransc.ics.repository.InfoJob;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducers;
+import org.oransc.ics.repository.InfoType;
+import org.oransc.ics.repository.InfoTypes;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers.r1consumer;
+package org.oransc.ics.controllers.r1consumer;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
 
-import org.oransc.enrichment.clients.AsyncRestClient;
-import org.oransc.enrichment.clients.AsyncRestClientFactory;
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.repository.InfoType;
-import org.oransc.enrichment.repository.InfoTypeSubscriptions;
+import org.oransc.ics.clients.AsyncRestClient;
+import org.oransc.ics.clients.AsyncRestClientFactory;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.repository.InfoType;
+import org.oransc.ics.repository.InfoTypeSubscriptions;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
 import reactor.core.publisher.Mono;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers.r1consumer;
+package org.oransc.ics.controllers.r1consumer;
 
 import com.fasterxml.jackson.databind.ObjectMapper;
 import com.google.gson.Gson;
@@ -41,17 +41,17 @@ import java.util.Collection;
 import java.util.List;
 
 import org.json.JSONObject;
-import org.oransc.enrichment.controllers.ErrorResponse;
-import org.oransc.enrichment.controllers.VoidResponse;
-import org.oransc.enrichment.controllers.r1producer.ProducerCallbacks;
-import org.oransc.enrichment.exceptions.ServiceException;
-import org.oransc.enrichment.repository.InfoJob;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducer;
-import org.oransc.enrichment.repository.InfoProducers;
-import org.oransc.enrichment.repository.InfoType;
-import org.oransc.enrichment.repository.InfoTypeSubscriptions;
-import org.oransc.enrichment.repository.InfoTypes;
+import org.oransc.ics.controllers.ErrorResponse;
+import org.oransc.ics.controllers.VoidResponse;
+import org.oransc.ics.controllers.r1producer.ProducerCallbacks;
+import org.oransc.ics.exceptions.ServiceException;
+import org.oransc.ics.repository.InfoJob;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducer;
+import org.oransc.ics.repository.InfoProducers;
+import org.oransc.ics.repository.InfoType;
+import org.oransc.ics.repository.InfoTypeSubscriptions;
+import org.oransc.ics.repository.InfoTypes;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers.r1producer;
+package org.oransc.ics.controllers.r1producer;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
@@ -27,13 +27,13 @@ import java.lang.invoke.MethodHandles;
 import java.time.Duration;
 import java.util.Collection;
 
-import org.oransc.enrichment.clients.AsyncRestClient;
-import org.oransc.enrichment.clients.AsyncRestClientFactory;
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.repository.InfoJob;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducer;
-import org.oransc.enrichment.repository.InfoProducers;
+import org.oransc.ics.clients.AsyncRestClient;
+import org.oransc.ics.clients.AsyncRestClientFactory;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.repository.InfoJob;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducer;
+import org.oransc.ics.repository.InfoProducers;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers.r1producer;
+package org.oransc.ics.controllers.r1producer;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
@@ -38,16 +38,16 @@ import java.util.ArrayList;
 import java.util.Collection;
 import java.util.List;
 
-import org.oransc.enrichment.controllers.ErrorResponse;
-import org.oransc.enrichment.controllers.VoidResponse;
-import org.oransc.enrichment.exceptions.ServiceException;
-import org.oransc.enrichment.repository.InfoJob;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducer;
-import org.oransc.enrichment.repository.InfoProducers;
-import org.oransc.enrichment.repository.InfoType;
-import org.oransc.enrichment.repository.InfoTypeSubscriptions;
-import org.oransc.enrichment.repository.InfoTypes;
+import org.oransc.ics.controllers.ErrorResponse;
+import org.oransc.ics.controllers.VoidResponse;
+import org.oransc.ics.exceptions.ServiceException;
+import org.oransc.ics.repository.InfoJob;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducer;
+import org.oransc.ics.repository.InfoProducers;
+import org.oransc.ics.repository.InfoType;
+import org.oransc.ics.repository.InfoTypeSubscriptions;
+import org.oransc.ics.repository.InfoTypes;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.http.HttpStatus;
 import org.springframework.http.MediaType;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controllers.r1producer;
+package org.oransc.ics.controllers.r1producer;
 
 import com.fasterxml.jackson.annotation.JsonProperty;
 import com.google.gson.annotations.SerializedName;
@@ -26,7 +26,7 @@ import com.google.gson.annotations.SerializedName;
 import io.swagger.v3.oas.annotations.media.Schema;
 
 import org.immutables.gson.Gson;
-import org.oransc.enrichment.repository.InfoJob;
+import org.oransc.ics.repository.InfoJob;
 
 @Gson.TypeAdapters
 @Schema(
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.repository;
+package org.oransc.ics.repository;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
@@ -38,9 +38,9 @@ import java.util.Map;
 import java.util.ServiceLoader;
 import java.util.Vector;
 
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.controllers.r1producer.ProducerCallbacks;
-import org.oransc.enrichment.exceptions.ServiceException;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.controllers.r1producer.ProducerCallbacks;
+import org.oransc.ics.exceptions.ServiceException;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.http.HttpStatus;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.repository;
+package org.oransc.ics.repository;
 
 import java.lang.invoke.MethodHandles;
 import java.util.ArrayList;
@@ -30,9 +30,9 @@ import java.util.Vector;
 import lombok.Builder;
 import lombok.Getter;
 
-import org.oransc.enrichment.controllers.a1e.A1eCallbacks;
-import org.oransc.enrichment.controllers.r1producer.ProducerCallbacks;
-import org.oransc.enrichment.exceptions.ServiceException;
+import org.oransc.ics.controllers.a1e.A1eCallbacks;
+import org.oransc.ics.controllers.r1producer.ProducerCallbacks;
+import org.oransc.ics.exceptions.ServiceException;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.repository;
+package org.oransc.ics.repository;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
@@ -41,8 +41,8 @@ import java.util.function.Function;
 import lombok.Builder;
 import lombok.Getter;
 
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.exceptions.ServiceException;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.exceptions.ServiceException;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.repository;
+package org.oransc.ics.repository;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
@@ -38,8 +38,8 @@ import java.util.Map;
 import java.util.ServiceLoader;
 import java.util.Vector;
 
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.exceptions.ServiceException;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.exceptions.ServiceException;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.http.HttpStatus;
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.tasks;
+package org.oransc.ics.tasks;
 
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.controllers.a1e.A1eCallbacks;
-import org.oransc.enrichment.controllers.r1producer.ProducerCallbacks;
-import org.oransc.enrichment.repository.InfoJob;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducer;
-import org.oransc.enrichment.repository.InfoProducers;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.controllers.a1e.A1eCallbacks;
+import org.oransc.ics.controllers.r1producer.ProducerCallbacks;
+import org.oransc.ics.repository.InfoJob;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducer;
+import org.oransc.ics.repository.InfoProducers;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment;
+package org.oransc.ics;
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.awaitility.Awaitility.await;
@@ -41,40 +41,40 @@ import org.junit.jupiter.api.AfterEach;
 import org.junit.jupiter.api.BeforeEach;
 import org.junit.jupiter.api.Test;
 import org.junit.jupiter.api.extension.ExtendWith;
-import org.oransc.enrichment.clients.AsyncRestClient;
-import org.oransc.enrichment.clients.AsyncRestClientFactory;
-import org.oransc.enrichment.configuration.ApplicationConfig;
-import org.oransc.enrichment.configuration.ImmutableHttpProxyConfig;
-import org.oransc.enrichment.configuration.ImmutableWebClientConfig;
-import org.oransc.enrichment.configuration.WebClientConfig;
-import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
-import org.oransc.enrichment.controller.ConsumerSimulatorController;
-import org.oransc.enrichment.controller.ProducerSimulatorController;
-import org.oransc.enrichment.controllers.a1e.A1eConsts;
-import org.oransc.enrichment.controllers.a1e.A1eEiJobInfo;
-import org.oransc.enrichment.controllers.a1e.A1eEiJobStatus;
-import org.oransc.enrichment.controllers.a1e.A1eEiTypeInfo;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerConsts;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerInfoTypeInfo;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerJobInfo;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerJobStatus;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerTypeRegistrationInfo;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerTypeSubscriptionInfo;
-import org.oransc.enrichment.controllers.r1producer.ProducerCallbacks;
-import org.oransc.enrichment.controllers.r1producer.ProducerConsts;
-import org.oransc.enrichment.controllers.r1producer.ProducerInfoTypeInfo;
-import org.oransc.enrichment.controllers.r1producer.ProducerJobInfo;
-import org.oransc.enrichment.controllers.r1producer.ProducerRegistrationInfo;
-import org.oransc.enrichment.controllers.r1producer.ProducerStatusInfo;
-import org.oransc.enrichment.exceptions.ServiceException;
-import org.oransc.enrichment.repository.InfoJob;
-import org.oransc.enrichment.repository.InfoJobs;
-import org.oransc.enrichment.repository.InfoProducer;
-import org.oransc.enrichment.repository.InfoProducers;
-import org.oransc.enrichment.repository.InfoType;
-import org.oransc.enrichment.repository.InfoTypeSubscriptions;
-import org.oransc.enrichment.repository.InfoTypes;
-import org.oransc.enrichment.tasks.ProducerSupervision;
+import org.oransc.ics.clients.AsyncRestClient;
+import org.oransc.ics.clients.AsyncRestClientFactory;
+import org.oransc.ics.configuration.ApplicationConfig;
+import org.oransc.ics.configuration.ImmutableHttpProxyConfig;
+import org.oransc.ics.configuration.ImmutableWebClientConfig;
+import org.oransc.ics.configuration.WebClientConfig;
+import org.oransc.ics.configuration.WebClientConfig.HttpProxyConfig;
+import org.oransc.ics.controller.ConsumerSimulatorController;
+import org.oransc.ics.controller.ProducerSimulatorController;
+import org.oransc.ics.controllers.a1e.A1eConsts;
+import org.oransc.ics.controllers.a1e.A1eEiJobInfo;
+import org.oransc.ics.controllers.a1e.A1eEiJobStatus;
+import org.oransc.ics.controllers.a1e.A1eEiTypeInfo;
+import org.oransc.ics.controllers.r1consumer.ConsumerConsts;
+import org.oransc.ics.controllers.r1consumer.ConsumerInfoTypeInfo;
+import org.oransc.ics.controllers.r1consumer.ConsumerJobInfo;
+import org.oransc.ics.controllers.r1consumer.ConsumerJobStatus;
+import org.oransc.ics.controllers.r1consumer.ConsumerTypeRegistrationInfo;
+import org.oransc.ics.controllers.r1consumer.ConsumerTypeSubscriptionInfo;
+import org.oransc.ics.controllers.r1producer.ProducerCallbacks;
+import org.oransc.ics.controllers.r1producer.ProducerConsts;
+import org.oransc.ics.controllers.r1producer.ProducerInfoTypeInfo;
+import org.oransc.ics.controllers.r1producer.ProducerJobInfo;
+import org.oransc.ics.controllers.r1producer.ProducerRegistrationInfo;
+import org.oransc.ics.controllers.r1producer.ProducerStatusInfo;
+import org.oransc.ics.exceptions.ServiceException;
+import org.oransc.ics.repository.InfoJob;
+import org.oransc.ics.repository.InfoJobs;
+import org.oransc.ics.repository.InfoProducer;
+import org.oransc.ics.repository.InfoProducers;
+import org.oransc.ics.repository.InfoType;
+import org.oransc.ics.repository.InfoTypeSubscriptions;
+import org.oransc.ics.repository.InfoTypes;
+import org.oransc.ics.tasks.ProducerSupervision;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -182,7 +182,7 @@ class ApplicationTest {
         assertThat(jsonObj.remove("servers")).isNotNull();
 
         String indented = jsonObj.toString(4);
-        try (PrintStream out = new PrintStream(new FileOutputStream("api/ecs-api.json"))) {
+        try (PrintStream out = new PrintStream(new FileOutputStream("api/ics-api.json"))) {
             out.print(indented);
         }
     }
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controller;
+package org.oransc.ics.controller;
 
 import io.swagger.v3.oas.annotations.Operation;
 import io.swagger.v3.oas.annotations.media.Content;
@@ -34,11 +34,11 @@ import java.util.List;
 
 import lombok.Getter;
 
-import org.oransc.enrichment.controllers.VoidResponse;
-import org.oransc.enrichment.controllers.a1e.A1eConsts;
-import org.oransc.enrichment.controllers.a1e.A1eEiJobStatus;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerConsts;
-import org.oransc.enrichment.controllers.r1consumer.ConsumerTypeRegistrationInfo;
+import org.oransc.ics.controllers.VoidResponse;
+import org.oransc.ics.controllers.a1e.A1eConsts;
+import org.oransc.ics.controllers.a1e.A1eEiJobStatus;
+import org.oransc.ics.controllers.r1consumer.ConsumerConsts;
+import org.oransc.ics.controllers.r1consumer.ConsumerTypeRegistrationInfo;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.http.HttpStatus;
@@ -18,7 +18,7 @@
  * ========================LICENSE_END===================================
  */
 
-package org.oransc.enrichment.controller;
+package org.oransc.ics.controller;
 
 import io.swagger.v3.oas.annotations.Operation;
 import io.swagger.v3.oas.annotations.media.Content;
@@ -34,10 +34,10 @@ import java.util.List;
 
 import lombok.Getter;
 
-import org.oransc.enrichment.controllers.ErrorResponse;
-import org.oransc.enrichment.controllers.VoidResponse;
-import org.oransc.enrichment.controllers.r1producer.ProducerConsts;
-import org.oransc.enrichment.controllers.r1producer.ProducerJobInfo;
+import org.oransc.ics.controllers.ErrorResponse;
+import org.oransc.ics.controllers.VoidResponse;
+import org.oransc.ics.controllers.r1producer.ProducerConsts;
+import org.oransc.ics.controllers.r1producer.ProducerJobInfo;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.http.HttpStatus;
diff --git a/pom.xml b/pom.xml
index e0665a1..d4f5500 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -34,7 +34,7 @@
     </properties>
     <modules>
         <module>policy-agent</module>
-        <module>enrichment-coordinator-service</module>
+        <module>information-coordinator-service</module>
         <module>r-app-catalogue</module>
         <module>helm-manager</module>
         <module>dmaap-adaptor-java</module>
index a9acd6e..1b82ea0 100644 (file)
@@ -122,7 +122,11 @@ __CR_statisics_setup() {
                        CR_INSTANCE_KUBE=$(($CR_INSTANCE-1))
                        echo -n " CR-$CR_INSTANCE_KUBE $CR_APP_NAME-$CR_INSTANCE_KUBE $KUBE_SIM_NAMESPACE "
                else
-                       echo -n " CR_$CR_INSTANCE ${CR_APP_NAME}_cr_$CR_INSTANCE "
+                       if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                               echo -n " CR_$CR_INSTANCE ${CR_APP_NAME}_cr_$CR_INSTANCE "
+                       else
+                               echo -n " CR_$CR_INSTANCE ${CR_APP_NAME}-cr-$CR_INSTANCE "
+                       fi
                fi
        done
 }
@@ -161,7 +165,11 @@ __cr_set_protocoll() {
        for ((CR_INSTANCE=0; CR_INSTANCE<$MAX_CR_APP_COUNT; CR_INSTANCE++ )); do
                CR_DOCKER_INSTANCE=$(($CR_INSTANCE+1))
                # CR_SERVICE_PATH is the base path to cr
-               __CR_SERVICE_PATH=$1"://"$CR_APP_NAME"_cr_"${CR_DOCKER_INSTANCE}":"$2  # docker access, container->container and script->container via proxy
+               if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                       __CR_SERVICE_PATH=$1"://"$CR_APP_NAME"_cr_"${CR_DOCKER_INSTANCE}":"$2  # docker access, container->container and script->container via proxy
+               else
+                       __CR_SERVICE_PATH=$1"://"$CR_APP_NAME"-cr-"${CR_DOCKER_INSTANCE}":"$2  # docker access, container->container and script->container via proxy
+               fi
                if [ $RUNMODE == "KUBE" ]; then
                        __CR_SERVICE_PATH=$1"://"$CR_APP_NAME"-"$CR_INSTANCE.$CR_APP_NAME"."$KUBE_SIM_NAMESPACE":"$3 # kube access, pod->svc and script->svc via proxy
                fi
@@ -285,7 +293,11 @@ start_cr() {
                app_data=""
                cntr=1
                while [ $cntr -le $CR_APP_COUNT ]; do
-                       app=$CR_APP_NAME"_cr_"$cntr
+                       if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                               app=$CR_APP_NAME"_cr_"$cntr
+                       else
+                               app=$CR_APP_NAME"-cr-"$cntr
+                       fi
                        app_data="$app_data $app"
                        let cntr=cntr+1
                done
@@ -297,7 +309,11 @@ start_cr() {
                cntr=1   #Counter for docker instance, starts on 1
                cntr2=0  #Couter for env var name, starts with 0 to be compablible with kube
                while [ $cntr -le $CR_APP_COUNT ]; do
-                       app=$CR_APP_NAME"_cr_"$cntr
+                       if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                               app=$CR_APP_NAME"_cr_"$cntr
+                       else
+                               app=$CR_APP_NAME"-cr-"$cntr
+                       fi
                        __dynvar="CR_SERVICE_PATH_"$cntr2
                        __check_service_start $app ${!__dynvar}$CR_ALIVE_URL
                        let cntr=cntr+1
index 2adce1f..e186f09 100755 (executable)
@@ -31,7 +31,6 @@ print_usage() {
   echo "or"
   echo "Usage: genstat.sh KUBE <start-time-seconds> <log-file> <app-short-name> <app-name> <namespace> [ <app-short-name> <app-name> <namespace> ]*"
 }
-DD=$@
 STARTTIME=-1
 
 if [ $# -lt 4 ]; then
@@ -67,7 +66,6 @@ fi
 
 
 echo "Name;Time;PIDS;CPU perc;Mem perc" > $LOGFILE
-echo $DD >> $LOGFILE
 
 if [ "$STARTTIME" -ne -1 ]; then
     STARTTIME=$(($SECONDS-$STARTTIME))
index 2002131..c6feb45 100755 (executable)
@@ -372,6 +372,9 @@ __dmaapmr_export_vars() {
 
        export MR_KAFKA_SERVICE_PATH
        export MR_ZOOKEEPER_SERVICE_PATH
+
+       export MR_KAFKA_KUBE_NODE_PORT
+       export MR_KAFKA_DOCKER_LOCALHOST_PORT
 }
 
 # Export env vars for config files, docker compose and kube resources
@@ -509,6 +512,9 @@ start_mr() {
 
                        __check_service_start $MR_DMAAP_APP_NAME $MR_DMAAP_PATH$MR_DMAAP_ALIVE_URL
 
+                       echo " Kafka TCP node port $MR_KAFKA_KUBE_NODE_PORT"
+
+
                        if [ $# -gt 0 ]; then
                                if [ $(($#%3)) -eq 0 ]; then
                                        while [ $# -gt 0 ]; do
@@ -608,6 +614,8 @@ start_mr() {
 
                        __check_service_start $MR_DMAAP_APP_NAME $MR_DMAAP_PATH$MR_DMAAP_ALIVE_URL
 
+                       echo " Kafka TCP node port $MR_KAFKA_DOCKER_LOCALHOST_PORT"
+
                        if [ $# -gt 0 ]; then
                                if [ $(($#%3)) -eq 0 ]; then
                                        while [ $# -gt 0 ]; do
index 5367060..219aedb 100644 (file)
@@ -533,7 +533,11 @@ prepare_consul_config() {
                        ric_id=${ric%.*.*} #extract pod id from full hosthame
                        ric_id=$(echo "$ric_id" | tr '-' '_')
                else
-                       ric_id=$ric
+                       if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                               ric_id=$ric
+                       else
+                               ric_id=$(echo "$ric" | tr '-' '_')  #ric id still needs underscore as it is different from the container name
+                       fi
                fi
                echo " Found a1 sim: "$ric_id
                config_json=$config_json"\n            \"name\": \"$ric_id\","
index 0a1a8e3..435c208 100644 (file)
@@ -103,9 +103,15 @@ __RICSIM_statisics_setup() {
                        echo -n " RICSIM_G2_$RICSIM_INSTANCE_KUBE ${RIC_SIM_PREFIX}-g2-$RICSIM_INSTANCE_KUBE $KUBE_A1SIM_NAMESPACE "
                        echo -n " RICSIM_G3_$RICSIM_INSTANCE_KUBE ${RIC_SIM_PREFIX}-g3-$RICSIM_INSTANCE_KUBE $KUBE_A1SIM_NAMESPACE "
                else
-                       echo -n " RICSIM_G1_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}_g1_$RICSIM_INSTANCE "
-                       echo -n " RICSIM_G2_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}_g2_$RICSIM_INSTANCE "
-                       echo -n " RICSIM_G3_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}_g3_$RICSIM_INSTANCE "
+                       if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                               echo -n " RICSIM_G1_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}_g1_$RICSIM_INSTANCE "
+                               echo -n " RICSIM_G2_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}_g2_$RICSIM_INSTANCE "
+                               echo -n " RICSIM_G3_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}_g3_$RICSIM_INSTANCE "
+                       else
+                               echo -n " RICSIM_G1_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}-g1-$RICSIM_INSTANCE "
+                               echo -n " RICSIM_G2_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}-g2-$RICSIM_INSTANCE "
+                               echo -n " RICSIM_G3_$RICSIM_INSTANCE ${RIC_SIM_PREFIX}-g3-$RICSIM_INSTANCE "
+                       fi
                fi
        done
 }
@@ -114,16 +120,10 @@ __RICSIM_statisics_setup() {
 
 
 RIC_SIM_HTTPX="http"
-RIC_SIM_HOST=$RIC_SIM_HTTPX"://"$LOCALHOST_NAME
 RIC_SIM_PORT=$RIC_SIM_INTERNAL_PORT
 
 
-#Vars for A1 interface version and container count
-G1_A1_VERSION=""
-G2_A1_VERSION=""
-G3_A1_VERSION=""
-G4_A1_VERSION=""
-G5_A1_VERSION=""
+#Vars for container count
 G1_COUNT=0
 G2_COUNT=0
 G3_COUNT=0
@@ -139,7 +139,6 @@ use_simulator_http() {
        echo -e $BOLD"RICSIM protocol setting"$EBOLD
        echo -e " Using $BOLD http $EBOLD towards the simulators"
        RIC_SIM_HTTPX="http"
-       RIC_SIM_HOST=$RIC_SIM_HTTPX"://"$LOCALHOST_NAME
        RIC_SIM_PORT=$RIC_SIM_INTERNAL_PORT
        echo ""
 }
@@ -148,7 +147,6 @@ use_simulator_https() {
        echo -e $BOLD"RICSIM protocol setting"$EBOLD
        echo -e " Using $BOLD https $EBOLD towards the simulators"
        RIC_SIM_HTTPX="https"
-       RIC_SIM_HOST=$RIC_SIM_HTTPX"://"$LOCALHOST_NAME
        RIC_SIM_PORT=$RIC_SIM_INTERNAL_SECURE_PORT
        echo ""
 }
@@ -208,19 +206,14 @@ start_ric_simulators() {
        #Set env var for simulator count and A1 interface vesion for the given group
        if [ $1 == "$RIC1" ]; then
                G1_COUNT=$2
-               G1_A1_VERSION=$3
        elif [ $1 == "$RIC2" ]; then
                G2_COUNT=$2
-               G2_A1_VERSION=$3
        elif [ $1 == "$RIC3" ]; then
                G3_COUNT=$2
-               G3_A1_VERSION=$3
        elif [ $1 == "$RIC4" ]; then
                G4_COUNT=$2
-               G4_A1_VERSION=$3
        elif [ $1 == "$RIC5" ]; then
                G5_COUNT=$2
-               G5_A1_VERSION=$3
        else
                ((RES_CONF_FAIL++))
                __print_err "need three args, $RIC1|$RIC2|$RIC3|$RIC4|$RIC5 <count> <interface-id>" $@
@@ -275,22 +268,34 @@ start_ric_simulators() {
                # Create .env file to compose project, all ric container will get this prefix
                echo "COMPOSE_PROJECT_NAME="$RIC_SIM_PREFIX > $SIM_GROUP/$RIC_SIM_COMPOSE_DIR/.env
 
-               export G1_A1_VERSION
-               export G2_A1_VERSION
-               export G3_A1_VERSION
-               export G4_A1_VERSION
-               export G5_A1_VERSION
+               #extract service name (group), g1, g2, g3, g4 or g5 from var $1
+               #E.g. ricsim_g1 -> g1 is the service name
+               TMP_GRP=$1
+               RICSIM_COMPOSE_SERVICE_NAME=$(echo "${TMP_GRP##*_}")
+
+               export RICSIM_COMPOSE_A1_VERSION=$3
+               export RICSIM_COMPOSE_SERVICE_NAME
                export RIC_SIM_INTERNAL_PORT
                export RIC_SIM_INTERNAL_SECURE_PORT
                export RIC_SIM_CERT_MOUNT_DIR
                export DOCKER_SIM_NWNAME
                export RIC_SIM_DISPLAY_NAME
 
-               docker_args="--scale g1=$G1_COUNT --scale g2=$G2_COUNT --scale g3=$G3_COUNT --scale g4=$G4_COUNT --scale g5=$G5_COUNT"
+               docker_args="--no-recreate --scale $RICSIM_COMPOSE_SERVICE_NAME=$2"
+
+               #Create a list of contsiner names
+               #Will be <ricsim-prefix>_<service-name>_<index>
+               # or
+               # <ricsim-prefix>-<service-name>-<index>
                app_data=""
                cntr=1
+               if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                       app_name_prefix=$RIC_SIM_PREFIX"_"$RICSIM_COMPOSE_SERVICE_NAME"_"
+               else
+                       app_name_prefix=$RIC_SIM_PREFIX"-"$RICSIM_COMPOSE_SERVICE_NAME"-"
+               fi
                while [ $cntr -le $2 ]; do
-                       app=$1"_"$cntr
+                       app=$app_name_prefix$cntr
                        app_data="$app_data $app"
                        let cntr=cntr+1
                done
@@ -299,7 +304,11 @@ start_ric_simulators() {
 
                cntr=1
                while [ $cntr -le $2 ]; do
-                       app=$1"_"$cntr
+                       if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                               app=$RIC_SIM_PREFIX"_"$RICSIM_COMPOSE_SERVICE_NAME"_"$cntr
+                       else
+                               app=$RIC_SIM_PREFIX"-"$RICSIM_COMPOSE_SERVICE_NAME"-"$cntr
+                       fi
                        __check_service_start $app $RIC_SIM_HTTPX"://"$app:$RIC_SIM_PORT$RIC_SIM_ALIVE_URL
                        let cntr=cntr+1
                done
@@ -329,7 +338,12 @@ __find_sim_host() {
                ric_setname="${ricname%-*}"  #Extract the stateful set name
                echo $RIC_SIM_HTTPX"://"$ricname.$ric_setname.$KUBE_A1SIM_NAMESPACE":"$RIC_SIM_PORT
        else
-               echo $RIC_SIM_HTTPX"://"$1":"$RIC_SIM_PORT
+               if [ $DOCKER_COMPOSE_VERION == "V1" ]; then
+                       echo $RIC_SIM_HTTPX"://"$1":"$RIC_SIM_PORT
+               else
+                       ricname=$(echo "$1" | tr '_' '-')
+                       echo $RIC_SIM_HTTPX"://"$ricname":"$RIC_SIM_PORT
+               fi
 
        fi
 }
index 4ae753c..3254e06 100755 (executable)
@@ -212,6 +212,8 @@ MR_DMAAP_COMPOSE_DIR="dmaapmr"                           # Dir in simulator_grou
 MR_STUB_COMPOSE_DIR="mrstub"                             # Dir in simulator_group for mr stub for - docker-compose
 MR_KAFKA_APP_NAME="message-router-kafka"                 # Kafka app name, if just named "kafka" the image will not start...
 MR_KAFKA_PORT=9092                                       # Kafka port number
+MR_KAFKA_DOCKER_LOCALHOST_PORT=30098                     # Kafka port number for docker localhost
+MR_KAFKA_KUBE_NODE_PORT=30099                            # Kafka node port number for kube
 MR_ZOOKEEPER_APP_NAME="zookeeper"                        # Zookeeper app name
 MR_ZOOKEEPER_PORT="2181"                                 # Zookeeper port number
 MR_DMAAP_HOST_MNT_DIR="/mnt"                             # Basedir localhost for mounted files
index 17d738f..f82d54f 100755 (executable)
@@ -256,6 +256,8 @@ MR_DMAAP_COMPOSE_DIR="dmaapmr"                           # Dir in simulator_grou
 MR_STUB_COMPOSE_DIR="mrstub"                             # Dir in simulator_group for mr stub for - docker-compose
 MR_KAFKA_APP_NAME="message-router-kafka"                 # Kafka app name, if just named "kafka" the image will not start...
 MR_KAFKA_PORT=9092                                       # Kafka port number
+MR_KAFKA_DOCKER_LOCALHOST_PORT=30098                     # Kafka port number for docker localhost
+MR_KAFKA_KUBE_NODE_PORT=30099                            # Kafka node port number for kube
 MR_ZOOKEEPER_APP_NAME="zookeeper"                        # Zookeeper app name
 MR_ZOOKEEPER_PORT="2181"                                 # Zookeeper port number
 MR_DMAAP_HOST_MNT_DIR="/mnt"                             # Basedir localhost for mounted files
index 2a6268e..b2b0d2e 100644 (file)
@@ -259,6 +259,8 @@ MR_DMAAP_COMPOSE_DIR="dmaapmr"                           # Dir in simulator_grou
 MR_STUB_COMPOSE_DIR="mrstub"                             # Dir in simulator_group for mr stub for - docker-compose
 MR_KAFKA_APP_NAME="message-router-kafka"                 # Kafka app name, if just named "kafka" the image will not start...
 MR_KAFKA_PORT=9092                                       # Kafka port number
+MR_KAFKA_DOCKER_LOCALHOST_PORT=30098                     # Kafka port number for docker localhost
+MR_KAFKA_KUBE_NODE_PORT=30099                            # Kafka node port number for kube
 MR_ZOOKEEPER_APP_NAME="zookeeper"                        # Zookeeper app name
 MR_ZOOKEEPER_PORT="2181"                                 # Zookeeper port number
 MR_DMAAP_HOST_MNT_DIR="/mnt"                             # Basedir localhost for mounted files
index 513afaa..b1204cc 100755 (executable)
@@ -259,6 +259,8 @@ MR_DMAAP_COMPOSE_DIR="dmaapmr"                           # Dir in simulator_grou
 MR_STUB_COMPOSE_DIR="mrstub"                             # Dir in simulator_group for mr stub for - docker-compose
 MR_KAFKA_APP_NAME="message-router-kafka"                 # Kafka app name, if just named "kafka" the image will not start...
 MR_KAFKA_PORT=9092                                       # Kafka port number
+MR_KAFKA_DOCKER_LOCALHOST_PORT=30098                     # Kafka port number for docker localhost
+MR_KAFKA_KUBE_NODE_PORT=30099                            # Kafka node port number for kube
 MR_ZOOKEEPER_APP_NAME="zookeeper"                        # Zookeeper app name
 MR_ZOOKEEPER_PORT="2181"                                 # Zookeeper port number
 MR_DMAAP_HOST_MNT_DIR="/mnt"                             # Basedir localhost for mounted files
index 7e495ee..cde9849 100755 (executable)
@@ -278,6 +278,8 @@ MR_DMAAP_COMPOSE_DIR="dmaapmr"                           # Dir in simulator_grou
 MR_STUB_COMPOSE_DIR="mrstub"                             # Dir in simulator_group for mr stub for - docker-compose
 MR_KAFKA_APP_NAME="message-router-kafka"                 # Kafka app name, if just named "kafka" the image will not start...
 MR_KAFKA_PORT=9092                                       # Kafka port number
+MR_KAFKA_DOCKER_LOCALHOST_PORT=30098                     # Kafka port number for docker localhost
+MR_KAFKA_KUBE_NODE_PORT=30099                            # Kafka node port number for kube
 MR_ZOOKEEPER_APP_NAME="zookeeper"                        # Zookeeper app name
 MR_ZOOKEEPER_PORT="2181"                                 # Zookeeper port number
 MR_DMAAP_HOST_MNT_DIR="/mnt"                             # Basedir localhost for mounted files
index fc547fe..cd0d040 100755 (executable)
@@ -304,6 +304,8 @@ MR_DMAAP_COMPOSE_DIR="dmaapmr"                           # Dir in simulator_grou
 MR_STUB_COMPOSE_DIR="mrstub"                             # Dir in simulator_group for mr stub for - docker-compose
 MR_KAFKA_APP_NAME="message-router-kafka"                 # Kafka app name, if just named "kafka" the image will not start...
 MR_KAFKA_PORT=9092                                       # Kafka port number
+MR_KAFKA_DOCKER_LOCALHOST_PORT=30098                     # Kafka port number for docker localhost
+MR_KAFKA_KUBE_NODE_PORT=30099                            # Kafka node port number for kube
 MR_ZOOKEEPER_APP_NAME="zookeeper"                        # Zookeeper app name
 MR_ZOOKEEPER_PORT="2181"                                 # Zookeeper port number
 MR_DMAAP_HOST_MNT_DIR="/mnt"                             # Basedir localhost for mounted files
index b47413a..e1c90d6 100755 (executable)
@@ -128,6 +128,11 @@ STOP_AT_ERROR=0
 # Applies only to images defined in the test-env files with image names and tags defined as XXXX_RELEASE
 IMAGE_CATEGORY="DEV"
 
+#Var to indicate docker-compose version, V1 or V2
+#V1 names replicated containers <proj-name>_<service-name>_<index>
+#V2 names replicated containers <proj-name>-<service-name>-<index>
+DOCKER_COMPOSE_VERION="V1"
+
 # Function to indent cmd output with one space
 indent1() { sed 's/^/ /'; }
 
@@ -783,34 +788,44 @@ echo -e $BOLD"Auto adding included apps"$EBOLD
        done
 echo ""
 
+echo -e $BOLD"Test environment info"$EBOLD
 
 # Check needed installed sw
+
+tmp=$(which bash)
+if [ $? -ne 0 ] || [ -z "$tmp" ]; then
+       echo -e $RED"bash is required to run the test environment, pls install"$ERED
+       exit 1
+fi
+echo " bash is installed and using version:"
+echo "$(bash --version)" | indent2
+
 tmp=$(which python3)
-if [ $? -ne 0 ] || [ -z tmp ]; then
+if [ $? -ne 0 ] || [ -z "$tmp" ]; then
        echo -e $RED"python3 is required to run the test environment, pls install"$ERED
        exit 1
 fi
+echo " python3 is installed and using version: $(python3 --version)"
+
 tmp=$(which docker)
-if [ $? -ne 0 ] || [ -z tmp ]; then
+if [ $? -ne 0 ] || [ -z "$tmp" ]; then
        echo -e $RED"docker is required to run the test environment, pls install"$ERED
        exit 1
 fi
+echo " docker is installed and using versions:"
+echo  "  $(docker version --format 'Client version {{.Client.Version}} Server version {{.Server.Version}}')"
 
 tmp=$(which docker-compose)
-if [ $? -ne 0 ] || [ -z tmp ]; then
+if [ $? -ne 0 ] || [ -z "$tmp" ]; then
        if [ $RUNMODE == "DOCKER" ]; then
                echo -e $RED"docker-compose is required to run the test environment, pls install"$ERED
                exit 1
        fi
 fi
-if [ $RUNMODE == "DOCKER" ]; then
-       tmp=$(docker-compose version | grep -i 'docker' | grep -i 'compose' | grep -i 'version')
-       if [[ "$tmp" == *'v2'* ]]; then
-               echo -e $RED"docker-compose is using docker-compose version 2"$ERED
-               echo -e $RED"The test environment only support version 1"$ERED
-               echo -e $RED"Disable version 2 by cmd 'docker-compose disable-v2' and re-run the script "$ERED
-               exit 1
-       fi
+tmp=$(docker-compose version --short)
+echo " docker-compose installed and using version $tmp"
+if [[ "$tmp" == *'v2'* ]]; then
+       DOCKER_COMPOSE_VERION="V2"
 fi
 
 tmp=$(which kubectl)
@@ -821,6 +836,8 @@ if [ $? -ne 0 ] || [ -z tmp ]; then
        fi
 else
        if [ $RUNMODE == "KUBE" ]; then
+               echo " kubectl is installed and using versions:"
+               echo $(kubectl version --short=true) | indent2
                res=$(kubectl cluster-info 2>&1)
                if [ $? -ne 0 ]; then
                        echo -e "$BOLD$RED############################################# $ERED$EBOLD"
@@ -852,6 +869,8 @@ else
        fi
 fi
 
+echo ""
+
 echo -e $BOLD"Checking configured image setting for this test case"$EBOLD
 
 #Temp var to check for image variable name errors
@@ -1707,6 +1726,10 @@ __clean_containers() {
        for imagename in $APP_SHORT_NAMES; do
                docker ps -a --filter "label=nrttest_app=$imagename"  --filter "network=$DOCKER_SIM_NWNAME" --format ' {{.Label "nrttest_dp"}}\n{{.Label "nrttest_app"}}\n{{.Names}}' >> $running_contr_file
        done
+       running_contr_file_empty="No docker containers running, started by previous test execution"
+       if [ -s $running_contr_file ]; then
+               running_contr_file_empty=""
+       fi
 
        # Kill all containers started by the test env - to speed up shut down
     docker kill $(docker ps -a  --filter "label=nrttest_app" --format '{{.Names}}') &> /dev/null
@@ -1754,37 +1777,41 @@ __clean_containers() {
                tab_heading3="$tab_heading3"" "
        done
 
-       echo " $tab_heading1$tab_heading2$tab_heading3"" Actions"
-       cntr=0
-       while read p; do
-               if (( $cntr % 3 == 0 ));then
-                       row=""
-                       heading=$p
-                       heading_len=$tab_heading1_len
-               fi
-               if (( $cntr % 3 == 1));then
-                       heading=$p
-                       heading_len=$tab_heading2_len
-               fi
-               if (( $cntr % 3 == 2));then
-                       contr=$p
-                       heading=$p
-                       heading_len=$tab_heading3_len
-               fi
-               while (( ${#heading} < $heading_len)); do
-                       heading="$heading"" "
-               done
-               row=$row$heading
-               if (( $cntr % 3 == 2));then
-                       echo -ne $row$SAMELINE
-                       echo -ne " $row ${GREEN}stopping...${EGREEN}${SAMELINE}"
-                       docker stop $(docker ps -qa --filter name=${contr} --filter network=$DOCKER_SIM_NWNAME) &> /dev/null
-                       echo -ne " $row ${GREEN}stopped removing...${EGREEN}${SAMELINE}"
-                       docker rm --force $(docker ps -qa --filter name=${contr} --filter network=$DOCKER_SIM_NWNAME) &> /dev/null
-                       echo -e  " $row ${GREEN}stopped removed     ${EGREEN}"
-               fi
-               let cntr=cntr+1
-       done <$running_contr_file
+       if [ ! -z "$running_contr_file_empty" ]; then
+               echo $running_contr_file_empty | indent1
+       else
+               echo " $tab_heading1$tab_heading2$tab_heading3"" Actions"
+               cntr=0
+               while read p; do
+                       if (( $cntr % 3 == 0 ));then
+                               row=""
+                               heading=$p
+                               heading_len=$tab_heading1_len
+                       fi
+                       if (( $cntr % 3 == 1));then
+                               heading=$p
+                               heading_len=$tab_heading2_len
+                       fi
+                       if (( $cntr % 3 == 2));then
+                               contr=$p
+                               heading=$p
+                               heading_len=$tab_heading3_len
+                       fi
+                       while (( ${#heading} < $heading_len)); do
+                               heading="$heading"" "
+                       done
+                       row=$row$heading
+                       if (( $cntr % 3 == 2));then
+                               echo -ne $row$SAMELINE
+                               echo -ne " $row ${GREEN}stopping...${EGREEN}${SAMELINE}"
+                               docker stop $(docker ps -qa --filter name=${contr} --filter network=$DOCKER_SIM_NWNAME) &> /dev/null
+                               echo -ne " $row ${GREEN}stopped removing...${EGREEN}${SAMELINE}"
+                               docker rm --force $(docker ps -qa --filter name=${contr} --filter network=$DOCKER_SIM_NWNAME) &> /dev/null
+                               echo -e  " $row ${GREEN}stopped removed     ${EGREEN}"
+                       fi
+                       let cntr=cntr+1
+               done <$running_contr_file
+       fi
 
        echo ""
 
index 105c875..003dbfa 100644 (file)
@@ -19,9 +19,8 @@ version: '3.0'
 
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
-
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
 
   consul-server:
index 94628fa..b860a89 100644 (file)
@@ -17,8 +17,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   control-panel:
     image: ${CONTROL_PANEL_IMAGE}
index 3b63451..047ec45 100644 (file)
@@ -18,8 +18,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   cr:
     scale: $CR_APP_COUNT
index f9dee41..cea605a 100644 (file)
@@ -17,8 +17,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   dmaap-adapter-service:
     image: ${DMAAP_ADP_IMAGE}
index d0672df..e4c9a00 100644 (file)
@@ -17,8 +17,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   dmaap-mediator-service:
     image: ${DMAAP_MED_IMAGE}
index 01c9014..1a9d40a 100644 (file)
@@ -80,6 +80,8 @@ spec:
         ports:
         - name: http
           containerPort: $MR_KAFKA_PORT
+        - name: http-external
+          containerPort: $MR_KAFKA_KUBE_NODE_PORT
         env:
         - name: enableCadi
           value: 'false'
@@ -90,11 +92,11 @@ spec:
         - name: KAFKA_ZOOKEEPER_SESSION_TIMEOUT_MS
           value: '40000'
         - name: KAFKA_LISTENER_SECURITY_PROTOCOL_MAP
-          value: 'INTERNAL_PLAINTEXT:PLAINTEXT,EXTERNAL_PLAINTEXT:PLAINTEXT'
+          value: 'INTERNAL_PLAINTEXT:PLAINTEXT,EXTERNAL_PLAINTEXT:PLAINTEXT,PLAINTEXT_HOST:PLAINTEXT'
         - name: KAFKA_ADVERTISED_LISTENERS
-          value: 'INTERNAL_PLAINTEXT://$MR_KAFKA_SERVICE_PATH'
+          value: 'INTERNAL_PLAINTEXT://$MR_KAFKA_SERVICE_PATH,PLAINTEXT_HOST://localhost:$MR_KAFKA_KUBE_NODE_PORT'
         - name: KAFKA_LISTENERS
-          value: 'INTERNAL_PLAINTEXT://0.0.0.0:$MR_KAFKA_PORT'
+          value: 'INTERNAL_PLAINTEXT://0.0.0.0:$MR_KAFKA_PORT,PLAINTEXT_HOST://0.0.0.0:$MR_KAFKA_KUBE_NODE_PORT'
         - name: KAFKA_INTER_BROKER_LISTENER_NAME
           value: INTERNAL_PLAINTEXT
         - name: KAFKA_CONFLUENT_SUPPORT_METRICS_ENABLE
index 2060ce7..492fab1 100644 (file)
@@ -18,9 +18,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
-
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   zookeeper:
     image: $ONAP_ZOOKEEPER_IMAGE
@@ -51,14 +50,15 @@ services:
    container_name: $MR_KAFKA_APP_NAME
    ports:
     - "$MR_KAFKA_PORT:$MR_KAFKA_PORT"
+    - "$MR_KAFKA_DOCKER_LOCALHOST_PORT:$MR_KAFKA_DOCKER_LOCALHOST_PORT"
    environment:
     enableCadi: 'false'
     KAFKA_ZOOKEEPER_CONNECT: $MR_ZOOKEEPER_APP_NAME:$MR_ZOOKEEPER_PORT
     KAFKA_ZOOKEEPER_CONNECTION_TIMEOUT_MS: 40000
     KAFKA_ZOOKEEPER_SESSION_TIMEOUT_MS: 40000
-    KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: INTERNAL_PLAINTEXT:PLAINTEXT,EXTERNAL_PLAINTEXT:PLAINTEXT
-    KAFKA_ADVERTISED_LISTENERS: INTERNAL_PLAINTEXT://$MR_KAFKA_SERVICE_PATH
-    KAFKA_LISTENERS: INTERNAL_PLAINTEXT://0.0.0.0:$MR_KAFKA_PORT
+    KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: INTERNAL_PLAINTEXT:PLAINTEXT,EXTERNAL_PLAINTEXT:PLAINTEXT,PLAINTEXT_HOST:PLAINTEXT
+    KAFKA_ADVERTISED_LISTENERS: INTERNAL_PLAINTEXT://$MR_KAFKA_SERVICE_PATH,PLAINTEXT_HOST://localhost:$MR_KAFKA_DOCKER_LOCALHOST_PORT
+    KAFKA_LISTENERS: INTERNAL_PLAINTEXT://0.0.0.0:$MR_KAFKA_PORT,PLAINTEXT_HOST://0.0.0.0:$MR_KAFKA_DOCKER_LOCALHOST_PORT
     KAFKA_INTER_BROKER_LISTENER_NAME: INTERNAL_PLAINTEXT
     KAFKA_CONFLUENT_SUPPORT_METRICS_ENABLE: 'false'
     KAFKA_OPTS: -Djava.security.auth.login.config=/etc/kafka/secrets/jaas/zk_client_jaas.conf
index 446c59d..913b13e 100644 (file)
@@ -25,12 +25,17 @@ metadata:
     run: $MR_KAFKA_APP_NAME
     autotest: DMAAPMR
 spec:
-  type: ClusterIP
+  type: NodePort
   ports:
   - port: $MR_KAFKA_PORT
     targetPort: $MR_KAFKA_PORT
     protocol: TCP
     name: http
+  - port: $MR_KAFKA_KUBE_NODE_PORT
+    targetPort: $MR_KAFKA_KUBE_NODE_PORT
+    protocol: TCP
+    name: http-external
+    nodePort: $MR_KAFKA_KUBE_NODE_PORT
   selector:
     run: $MR_KAFKA_APP_NAME
 ---
index b057753..588f8c3 100644 (file)
@@ -16,8 +16,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   ecs:
     image: ${ECS_IMAGE}
index c27ba5e..2c8c61b 100644 (file)
@@ -18,8 +18,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   httpproxy:
     networks:
index 7f0f349..2e644e0 100644 (file)
@@ -17,8 +17,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   kubeproxy:
     image: ${KUBE_PROXY_IMAGE}
index a1c96c0..608f5c8 100644 (file)
@@ -18,8 +18,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   mr-stub:
     networks:
index c897ba7..7002eaf 100644 (file)
@@ -18,8 +18,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   nonrtric-gateway:
     image: ${NRT_GATEWAY_IMAGE}
index 2261151..4b42b42 100644 (file)
@@ -17,8 +17,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   policy-agent:
     image: ${POLICY_AGENT_IMAGE}
index e46c546..e05d3ad 100644 (file)
@@ -18,8 +18,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   producer-stub:
     networks:
index 3dbd45b..7c644b9 100644 (file)
@@ -17,8 +17,8 @@
 version: '3.0'
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   rapp-catalogue:
     image: ${RAPP_CAT_IMAGE}
index a6358c7..3515973 100644 (file)
@@ -21,11 +21,11 @@ version: '3.0'
 
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 
 services:
-  g1:
+  ${RICSIM_COMPOSE_SERVICE_NAME}:
     image: ${RIC_SIM_IMAGE}
     networks:
       - default
@@ -33,7 +33,7 @@ services:
       - ${RIC_SIM_INTERNAL_PORT}/tcp
       - ${RIC_SIM_INTERNAL_SECURE_PORT}/tcp
     environment:
-      - A1_VERSION=${G1_A1_VERSION}
+      - A1_VERSION=${RICSIM_COMPOSE_A1_VERSION}
       - REMOTE_HOSTS_LOGGING=1
       - ALLOW_HTTP=true
       - DUPLICATE_CHECK=1
@@ -42,75 +42,3 @@ services:
     labels:
       - "nrttest_app=RICSIM"
       - "nrttest_dp=${RIC_SIM_DISPLAY_NAME}"
-
-  g2:
-    image: ${RIC_SIM_IMAGE}
-    networks:
-      - default
-    ports:
-      - ${RIC_SIM_INTERNAL_PORT}/tcp
-      - ${RIC_SIM_INTERNAL_SECURE_PORT}/tcp
-    environment:
-      - A1_VERSION=${G2_A1_VERSION}
-      - REMOTE_HOSTS_LOGGING=1
-      - ALLOW_HTTP=true
-      - DUPLICATE_CHECK=1
-    volumes:
-      - ${RIC_SIM_CERT_MOUNT_DIR}:/usr/src/app/cert:ro
-    labels:
-      - "nrttest_app=RICSIM"
-      - "nrttest_dp=${RIC_SIM_DISPLAY_NAME}"
-
-  g3:
-    image: ${RIC_SIM_IMAGE}
-    networks:
-      - default
-    ports:
-      - ${RIC_SIM_INTERNAL_PORT}/tcp
-      - ${RIC_SIM_INTERNAL_SECURE_PORT}/tcp
-    environment:
-      - A1_VERSION=${G3_A1_VERSION}
-      - REMOTE_HOSTS_LOGGING=1
-      - ALLOW_HTTP=true
-      - DUPLICATE_CHECK=1
-    volumes:
-      - ${RIC_SIM_CERT_MOUNT_DIR}:/usr/src/app/cert:ro
-    labels:
-      - "nrttest_app=RICSIM"
-      - "nrttest_dp=${RIC_SIM_DISPLAY_NAME}"
-
-  g4:
-    image: ${RIC_SIM_IMAGE}
-    networks:
-      - default
-    ports:
-      - ${RIC_SIM_INTERNAL_PORT}/tcp
-      - ${RIC_SIM_INTERNAL_SECURE_PORT}/tcp
-    environment:
-      - A1_VERSION=${G4_A1_VERSION}
-      - REMOTE_HOSTS_LOGGING=1
-      - ALLOW_HTTP=true
-      - DUPLICATE_CHECK=1
-    volumes:
-      - ${RIC_SIM_CERT_MOUNT_DIR}:/usr/src/app/cert:ro
-    labels:
-      - "nrttest_app=RICSIM"
-      - "nrttest_dp=${RIC_SIM_DISPLAY_NAME}"
-
-  g5:
-    image: ${RIC_SIM_IMAGE}
-    networks:
-      - default
-    ports:
-      - ${RIC_SIM_INTERNAL_PORT}/tcp
-      - ${RIC_SIM_INTERNAL_SECURE_PORT}/tcp
-    environment:
-      - A1_VERSION=${G5_A1_VERSION}
-      - REMOTE_HOSTS_LOGGING=1
-      - ALLOW_HTTP=true
-      - DUPLICATE_CHECK=1
-    volumes:
-      - ${RIC_SIM_CERT_MOUNT_DIR}:/usr/src/app/cert:ro
-    labels:
-      - "nrttest_app=RICSIM"
-      - "nrttest_dp=${RIC_SIM_DISPLAY_NAME}"
\ No newline at end of file
index 03483a0..37c99b6 100644 (file)
@@ -17,9 +17,8 @@ version: '3.0'
 
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
-
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   db:
     image: ${SDNC_DB_IMAGE}
index 0b6f357..505a54c 100644 (file)
@@ -17,9 +17,8 @@ version: '3'
 
 networks:
   default:
-    external:
-      name: ${DOCKER_SIM_NWNAME}
-
+    external: true
+    name: ${DOCKER_SIM_NWNAME}
 services:
   db:
     image: ${SDNC_DB_IMAGE}