ADD /config/keystore.jks /opt/app/policy-agent/etc/cert/keystore.jks
ADD /config/truststore.jks /opt/app/policy-agent/etc/cert/truststore.jks
-RUN chmod -R 777 /opt/app/policy-agent/config/
-RUN chmod -R 777 /opt/app/policy-agent/data/
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+RUN chown -R appuser:appuser /opt/app/policy-agent
+RUN chown -R appuser:appuser /var/log/policy-agent
+USER appuser
ADD target/${JAR} /opt/app/policy-agent/policy-agent.jar
CMD ["java", "-jar", "/opt/app/policy-agent/policy-agent.jar"]
RUN mkdir -p /var/log/dmaap-adaptor-service
RUN mkdir -p /opt/app/dmaap-adaptor-service/etc/cert/
RUN mkdir -p /var/dmaap-adaptor-service
-RUN chmod -R 777 /var/dmaap-adaptor-service
ADD /config/application.yaml /opt/app/dmaap-adaptor-service/config/application.yaml
ADD /config/application_configuration.json /opt/app/dmaap-adaptor-service/data/application_configuration.json_example
ADD /config/keystore.jks /opt/app/dmaap-adaptor-service/etc/cert/keystore.jks
ADD /config/truststore.jks /opt/app/dmaap-adaptor-service/etc/cert/truststore.jks
-RUN chmod -R 777 /opt/app/dmaap-adaptor-service/config/
+
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+RUN chown -R appuser:appuser /var/dmaap-adaptor-service/
+RUN chown -R appuser:appuser /opt/app/dmaap-adaptor-service/
+USER appuser
ADD target/${JAR} /opt/app/dmaap-adaptor-service/dmaap-adaptor.jar
CMD ["java", "-jar", "/opt/app/dmaap-adaptor-service/dmaap-adaptor.jar"]
--- /dev/null
+#!/bin/bash
+##############################################################################
+#
+# Copyright (C) 2021: Nordix Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+##############################################################################
+
+go build
+
+go test ./...
--- /dev/null
+<!--
+ ============LICENSE_START=======================================================
+ Copyright (C) 2021 Nordix Foundation.
+ ================================================================================
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ SPDX-License-Identifier: Apache-2.0
+ ============LICENSE_END=========================================================
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+
+ <groupId>oransc.org</groupId>
+ <artifactId>dmaapmediatorproducer</artifactId>
+ <version>1.0.0</version>
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>exec-maven-plugin</artifactId>
+ <groupId>org.codehaus.mojo</groupId>
+ <executions>
+ <execution>
+ <id>Build Go binary</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>exec</goal>
+ </goals>
+ <configuration>
+ <executable>${basedir}/build_and_test.sh</executable>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
NONRTRIC_GATEWAY_IMAGE_BASE="nexus3.o-ran-sc.org:10002/o-ran-sc/nonrtric-gateway"
NONRTRIC_GATEWAY_IMAGE_TAG="1.0.0"
-#ECS
-ECS_IMAGE_BASE="nexus3.o-ran-sc.org:10002/o-ran-sc/nonrtric-information-coordinator-service"
-ECS_IMAGE_TAG="1.1.0"
+#ICS
+ICS_IMAGE_BASE="nexus3.o-ran-sc.org:10002/o-ran-sc/nonrtric-information-coordinator-service"
+ICS_IMAGE_TAG="1.1.0"
#CONSUMER
CONSUMER_IMAGE_BASE="eexit/mirror-http-server"
By default, if the containers are started up and running by docker-compose file in the same directory, just run commands:
./preparePmsData.sh
-prepareEcsData.sh
-This is to generate some data into the ECS microservice
+prepareIcsData.sh
+This is to generate some data into the ICS microservice
prepareDmaapMsg.sh
This is to generate some data into the Dmaap MR, so that PMS reads message from MR
To start all the necessary components, run the following command:
-docker-compose -f docker-compose.yaml -f control-panel/docker-compose.yaml -f nonrtric-gateway/docker-compose.yaml -f policy-service/docker-compose.yaml -f ecs/docker-compose.yaml -f a1-sim/docker-compose.yaml up
+docker-compose -f docker-compose.yaml -f control-panel/docker-compose.yaml -f nonrtric-gateway/docker-compose.yaml -f policy-service/docker-compose.yaml -f ics/docker-compose.yaml -f a1-sim/docker-compose.yaml up
# The scripts in data/ will generate some dummy data in the running system.
# It will create:
-# one EiProducer in ECS
-# one EiType in ECS
-# one EiJob in ECS
+# one InfoProducer in ICS
+# one InfoType in ICS
+# one InfoJob in ICS
# Run command:
-# ./prepareEcsData.sh [ECS port] [http/https]
+# ./prepareIcsData.sh [ICS port] [http/https]
-ecs_port=${1:-8083}
+ics_port=${1:-8083}
httpx=${4:-"http"}
SHELL_FOLDER=$(cd "$(dirname "$0")";pwd)
-echo "using ecs port: "$ecs_port
+echo "using ics port: "$ics_port
echo "using protocol: "$httpx
echo -e "\n"
-echo "ECS status:"
-curl -skw " %{http_code}" $httpx://localhost:$ecs_port/status
+echo "ICS status:"
+curl -skw " %{http_code}" $httpx://localhost:$ics_port/status
echo -e "\n"
-# Create EiType
-echo "Create EiType:"
-curl -X PUT -skw %{http_code} $httpx://localhost:$ecs_port/data-producer/v1/info-types/type1 -H accept:application/json -H Content-Type:application/json --data-binary @${SHELL_FOLDER}/testdata/ECS/EiType.json
+# Create InfoType
+echo "Create InfoType:"
+curl -X PUT -skw %{http_code} $httpx://localhost:$ics_port/data-producer/v1/info-types/type1 -H accept:application/json -H Content-Type:application/json --data-binary @${SHELL_FOLDER}/testdata/ICS/InfoType.json
echo -e "\n"
-# Get EiTypes
-echo "Get EiTypes:"
-curl -X GET -skw %{http_code} $httpx://localhost:$ecs_port/data-producer/v1/info-types -H Content-Type:application/json | jq
+# Get InfoTypes
+echo "Get InfoTypes:"
+curl -X GET -skw %{http_code} $httpx://localhost:$ics_port/data-producer/v1/info-types -H Content-Type:application/json | jq
echo -e "\n"
-# Get Individual EiType
-echo "Get Individual EiType:"
-curl -X GET -skw %{http_code} $httpx://localhost:$ecs_port/data-producer/v1/info-types/type1 -H Content-Type:application/json | jq
+# Get Individual InfoType
+echo "Get Individual InfoType:"
+curl -X GET -skw %{http_code} $httpx://localhost:$ics_port/data-producer/v1/info-types/type1 -H Content-Type:application/json | jq
echo -e "\n"
-# Create EiProducer
-echo "Create EiProducer:"
-curl -X PUT -skw %{http_code} $httpx://localhost:$ecs_port/data-producer/v1/info-producers/1 -H Content-Type:application/json --data-binary @${SHELL_FOLDER}/testdata/ECS/EiProducer.json
+# Create InfoProducer
+echo "Create InfoProducer:"
+curl -X PUT -skw %{http_code} $httpx://localhost:$ics_port/data-producer/v1/info-producers/1 -H Content-Type:application/json --data-binary @${SHELL_FOLDER}/testdata/ICS/InfoProducer.json
echo -e "\n"
-# Get EiProducers
-echo "Get EiProducers:"
-curl -X GET -skw %{http_code} $httpx://localhost:$ecs_port/data-producer/v1/info-producers -H Content-Type:application/json | jq
+# Get InfoProducers
+echo "Get InfoProducers:"
+curl -X GET -skw %{http_code} $httpx://localhost:$ics_port/data-producer/v1/info-producers -H Content-Type:application/json | jq
echo -e "\n"
-# Get Individual EiProducer
-echo "Get Individual EiProducer:"
-curl -X GET -skw %{http_code} $httpx://localhost:$ecs_port/data-producer/v1/info-producers/1 -H Content-Type:application/json | jq
+# Get Individual InfoProducer
+echo "Get Individual InfoProducer:"
+curl -X GET -skw %{http_code} $httpx://localhost:$ics_port/data-producer/v1/info-producers/1 -H Content-Type:application/json | jq
echo -e "\n"
-# Get Individual EiProducer Status
-echo "Get Individual EiProducer:"
-curl -X GET -skw %{http_code} $httpx://localhost:$ecs_port/data-producer/v1/info-producers/1/status -H Content-Type:application/json | jq
+# Get Individual InfoProducer Status
+echo "Get Individual InfoProducer:"
+curl -X GET -skw %{http_code} $httpx://localhost:$ics_port/data-producer/v1/info-producers/1/status -H Content-Type:application/json | jq
echo -e "\n"
-# Create EiJob
-echo "Create EiJob Of A Certain Type type1:"
-curl -X PUT -skw %{http_code} $httpx://localhost:$ecs_port/A1-EI/v1/eijobs/job1 -H Content-Type:application/json --data-binary @${SHELL_FOLDER}/testdata/ECS/EiJob.json
+# Create InfoJob
+echo "Create InfoJob Of A Certain Type type1:"
+curl -X PUT -skw %{http_code} $httpx://localhost:$ics_port/A1-EI/v1/eijobs/job1 -H Content-Type:application/json --data-binary @${SHELL_FOLDER}/testdata/ICS/InfoJob.json
echo -e "\n"
-# Get EiJobs
-echo "Get EiJobs:"
-curl -X GET -skw %{http_code} $httpx://localhost:$ecs_port/A1-EI/v1/eijobs -H Content-Type:application/json | jq
+# Get InfoJobs
+echo "Get InfoJobs:"
+curl -X GET -skw %{http_code} $httpx://localhost:$ics_port/A1-EI/v1/eijobs -H Content-Type:application/json | jq
echo -e "\n"
-# Get Individual EiJob:
-echo "Get Individual EiJob:"
-curl -X GET -skw %{http_code} $httpx://localhost:$ecs_port/A1-EI/v1/eijobs/job1 -H Content-Type:application/json | jq
+# Get Individual InfoJob:
+echo "Get Individual InfoJob:"
+curl -X GET -skw %{http_code} $httpx://localhost:$ics_port/A1-EI/v1/eijobs/job1 -H Content-Type:application/json | jq
echo -e "\n"
\ No newline at end of file
# ./sendMsgToMediator.sh [dmaap-mr port] [http/https]
SHELL_FOLDER=$(cd "$(dirname "$0")";pwd)
-bash ${SHELL_FOLDER}/prepareEcsData.sh
+bash ${SHELL_FOLDER}/prepareIcsData.sh
dmaa_mr_port=${1:-3904}
httpx=${2:-"http"}
@startuml
dmaap_mr <- dmaap_mediator: dmaap_mediator reads msg from dmaap_mr
-dmaap_mediator -> ecs: dmaap_mediator gets jobs from ecs
+dmaap_mediator -> ics: dmaap_mediator gets jobs from ics
dmaap_mediator -> consumer: callbackUrl, send msg to consumer
@enduml
\ No newline at end of file
http.proxy-host:
http.proxy-port: 0
vardata-directory: /var/dmaap-adaptor-service
- ecs-base-url: http://ecs:8083
+ ics-base-url: http://ics:8083
# Location of the component configuration file. The file will only be used if the Consul database is not used;
# configuration from the Consul will override the file.
configuration-filepath: /opt/app/dmaap-adaptor-service/data/application_configuration.json
* The A1 Policy Management Service
* The Information Coordinator Service
+* DMaaP Adaptor
* The Non-RT-RIC App Catalogue
* K8S Helm Chart LCM Manager (Initial) **<ToDo>**
:header: "API name", "|swagger-icon|", "|yaml-icon|"
:widths: 10,5,5
- "A1 Enrichment Information Coordination Service API", ":download:`link <../information-coordinator-service/api/ics-api.json>`", ":download:`link <../information-coordinator-service/api/ics-api.yaml>`"
+ "A1 Information Coordination Service API", ":download:`link <../information-coordinator-service/api/ics-api.json>`", ":download:`link <../information-coordinator-service/api/ics-api.yaml>`"
+
+DMaaP Adaptor
+=============
+
+The DMaaP Adaptor provides support for push delivery of any data received from DMaap or Kafka.
+
+See `DMaaP Adaptor API <./dmaap-adaptor-api.html>`_ for full details of the API.
+
+The API is also described in Swagger-JSON and YAML:
+
+
+.. csv-table::
+ :header: "API name", "|swagger-icon|", "|yaml-icon|"
+ :widths: 10,5, 5
+
+ "DMaaP Adaptor API", ":download:`link <../dmaap-adaptor-java/api/api.json>`", ":download:`link <../dmaap-adaptor-java/api/api.yaml>`"
Non-RT-RIC App Catalogue (Initial)
==================================
'http://127.0.0.1.*',
'https://gerrit.o-ran-sc.org.*',
'./rac-api.html', #Generated file that doesn't exist at link check.
- './ecs-api.html' #Generated file that doesn't exist at link check.
+ './ics-api.html', #Generated file that doesn't exist at link check.
+ './dmaap-adaptor-api.html' #Generated file that doesn't exist at link check.
]
extensions = ['sphinxcontrib.redoc', 'sphinx.ext.intersphinx',]
'embed': True,
},
{
- 'name': 'ECS API',
- 'page': 'ecs-api',
+ 'name': 'ICS API',
+ 'page': 'ics-api',
'spec': '../information-coordinator-service/api/ics-api.json',
'embed': True,
+ },
+ {
+ 'name': 'DMaaP Adaptor API',
+ 'page': 'dmaap-adaptor-api',
+ 'spec': '../dmaap-adaptor-java/api/api.json',
+ 'embed': True,
}
]
docker-compose -f docker-compose.yaml
-f policy-service/docker-compose.yaml
- -f ecs/docker-compose.yaml
+ -f ics/docker-compose.yaml
Install with Helm
+++++++++++++++++
* Non-RT-RIC (Kong) Service Exposure Prototyping
* Initial Non-RT-RIC App Catalogue
* Near-RT-RIC A1 Simulator
+* DMaap Adaptor
The code base for "D" Release is in the `NONRTRIC <https://gerrit.o-ran-sc.org/r/admin/repos/nonrtric>`_, `NONRTRIC-ControlPanel <https://gerrit.o-ran-sc.org/r/admin/repos/portal/nonrtric-controlpanel>`_, and `Near-RT-RIC A1-Simulator <https://gerrit.o-ran-sc.org/r/admin/repos/sim/a1-interface>`_ , Gerrit source repositories (D Branch).
See also: `A1 Policy Management Service in ONAP <https://wiki.onap.org/pages/viewpage.action?pageId=84672221>`_
+
+Implementation:
+* Implemented as a Java Spring Boot application
+
A1/SDNC Controller & A1 Adapter (Controller plugin)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
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>`_
-Information Job Coordination Service
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+Information Coordination Service
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Coordinate/Register A1-EI Types, Producers, Consumers, and Jobs.
* 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 Information exchange between NONRTRIC Apps*
+
+Implementation:
+* Implemented as a Java Spring Boot application
+
+Dmaap Adapter
+~~~~~~~~~~~~~
+
+Is a generic information producer, which registeres itself as an information producer of information types (in Information Coordination Service).
+The information types are defined in a configuration file.
+Information jobs can retrieve data from DMaap or Kafka topics and push this to data consumers (accessing the ICS API).
+
+Implementation:
+* Implemented as a Java Spring Boot application
+
Non-RT-RIC (Spring Cloud) Service Gateway
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Support Apps to use A1 Services
WORKDIR /opt/app/helm-manager
COPY target/app.jar app.jar
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+USER appuser
+
CMD [ "java", "-jar", "app.jar" ]
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/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/information-coordinator-service/config/
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+RUN chown -R appuser:appuser /opt/app/information-coordinator-service
+RUN chown -R appuser:appuser /var/information-coordinator-service
+RUN chown -R appuser:appuser /var/log/information-coordinator-service
+USER appuser
CMD ["java", "-jar", "/opt/app/information-coordinator-service/information-coordinator-service.jar"]
"description": "Void/empty ",
"type": "object"
},
+ "Link": {
+ "type": "object",
+ "properties": {
+ "templated": {"type": "boolean"},
+ "href": {"type": "string"}
+ }
+ },
"consumer_type_subscription_info": {
"description": "Information for an information type subscription",
"type": "object",
}],
"tags": ["A1-EI (registration)"]
}},
+ "/actuator/threaddump": {"get": {
+ "summary": "Actuator web endpoint 'threaddump'",
+ "operationId": "handle_2_1_3",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "tags": ["Actuator"]
+ }},
"/example_dataproducer/info_job": {"post": {
"summary": "Callback for Information Job creation/modification",
"requestBody": {
"tags": ["Data consumer"]
}
},
+ "/actuator/loggers": {"get": {
+ "summary": "Actuator web endpoint 'loggers'",
+ "operationId": "handle_6",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "tags": ["Actuator"]
+ }},
+ "/actuator/health/**": {"get": {
+ "summary": "Actuator web endpoint 'health-path'",
+ "operationId": "handle_12",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "tags": ["Actuator"]
+ }},
+ "/data-consumer/v1/info-types": {"get": {
+ "summary": "Information type identifiers",
+ "operationId": "getinfoTypeIdentifiers",
+ "responses": {"200": {
+ "description": "Information type identifiers",
+ "content": {"application/json": {"schema": {
+ "type": "array",
+ "items": {"type": "string"}
+ }}}
+ }},
+ "tags": ["Data consumer"]
+ }},
+ "/actuator/metrics/{requiredMetricName}": {"get": {
+ "summary": "Actuator web endpoint 'metrics-requiredMetricName'",
+ "operationId": "handle_5",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "parameters": [{
+ "schema": {"type": "string"},
+ "in": "path",
+ "name": "requiredMetricName",
+ "required": true
+ }],
+ "tags": ["Actuator"]
+ }},
+ "/actuator": {"get": {
+ "summary": "Actuator root web endpoint",
+ "operationId": "links_1",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {
+ "additionalProperties": {
+ "additionalProperties": {"$ref": "#/components/schemas/Link"},
+ "type": "object"
+ },
+ "type": "object"
+ }}}
+ }},
+ "tags": ["Actuator"]
+ }},
+ "/data-consumer/v1/info-jobs": {"get": {
+ "summary": "Information Job identifiers",
+ "description": "query for information job identifiers",
+ "operationId": "getJobIds",
+ "responses": {
+ "200": {
+ "description": "Information information job identifiers",
+ "content": {"application/json": {"schema": {
+ "type": "array",
+ "items": {"type": "string"}
+ }}}
+ },
+ "404": {
+ "description": "Information type is not found",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
+ }
+ },
+ "parameters": [
+ {
+ "schema": {"type": "string"},
+ "in": "query",
+ "name": "infoTypeId",
+ "description": "selects subscription jobs of matching information type",
+ "required": false
+ },
+ {
+ "schema": {"type": "string"},
+ "in": "query",
+ "name": "owner",
+ "description": "selects result for one owner",
+ "required": false
+ }
+ ],
+ "tags": ["Data consumer"]
+ }},
+ "/actuator/loggers/{name}": {
+ "post": {
+ "summary": "Actuator web endpoint 'loggers-name'",
+ "operationId": "handle_0",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "parameters": [{
+ "schema": {"type": "string"},
+ "in": "path",
+ "name": "name",
+ "required": true
+ }],
+ "tags": ["Actuator"]
+ },
+ "get": {
+ "summary": "Actuator web endpoint 'loggers-name'",
+ "operationId": "handle_7",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "parameters": [{
+ "schema": {"type": "string"},
+ "in": "path",
+ "name": "name",
+ "required": true
+ }],
+ "tags": ["Actuator"]
+ }
+ },
+ "/example_dataconsumer/info_jobs/{infoJobId}/status": {"post": {
+ "summary": "Callback for changed Information Job status",
+ "requestBody": {
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/EiJobStatusObject"}}},
+ "required": true
+ },
+ "description": "The primitive is implemented by the data consumer and is invoked when a Information Job status has been changed.",
+ "operationId": "jobStatusCallback",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/Void"}}}
+ }},
+ "parameters": [{
+ "schema": {"type": "string"},
+ "in": "path",
+ "name": "infoJobId",
+ "required": true
+ }],
+ "tags": ["A1-EI (callbacks)"]
+ }},
+ "/A1-EI/v1/eijobs/{eiJobId}/status": {"get": {
+ "summary": "EI job status",
+ "operationId": "getEiJobStatus_1",
+ "responses": {
+ "200": {
+ "description": "EI job status",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/EiJobStatusObject"}}}
+ },
+ "404": {
+ "description": "Enrichment Information job is not found",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
+ }
+ },
+ "parameters": [{
+ "schema": {"type": "string"},
+ "in": "path",
+ "name": "eiJobId",
+ "required": true
+ }],
+ "tags": ["A1-EI (registration)"]
+ }},
+ "/data-producer/v1/info-producers/{infoProducerId}/status": {"get": {
+ "summary": "Information producer status",
+ "operationId": "getInfoProducerStatus",
+ "responses": {
+ "200": {
+ "description": "Information producer status",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/producer_status"}}}
+ },
+ "404": {
+ "description": "Information producer is not found",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
+ }
+ },
+ "parameters": [{
+ "schema": {"type": "string"},
+ "in": "path",
+ "name": "infoProducerId",
+ "required": true
+ }],
+ "tags": ["Data producer (registration)"]
+ }},
+ "/data-consumer/v1/info-jobs/{infoJobId}/status": {"get": {
+ "summary": "Job status",
+ "operationId": "getEiJobStatus",
+ "responses": {
+ "200": {
+ "description": "Information subscription job status",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/consumer_job_status"}}}
+ },
+ "404": {
+ "description": "Information subscription job is not found",
+ "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
+ }
+ },
+ "parameters": [{
+ "schema": {"type": "string"},
+ "in": "path",
+ "name": "infoJobId",
+ "required": true
+ }],
+ "tags": ["Data consumer"]
+ }},
+ "/actuator/metrics": {"get": {
+ "summary": "Actuator web endpoint 'metrics'",
+ "operationId": "handle_4",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "tags": ["Actuator"]
+ }},
+ "/actuator/info": {"get": {
+ "summary": "Actuator web endpoint 'info'",
+ "operationId": "handle_9",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "tags": ["Actuator"]
+ }},
"/example_dataproducer/health_check": {"get": {
"summary": "Producer supervision",
"description": "The endpoint is provided by the Information Producer and is used for supervision of the producer.",
}},
"tags": ["A1-EI (registration)"]
}},
- "/data-consumer/v1/info-types": {"get": {
- "summary": "Information type identifiers",
- "operationId": "getinfoTypeIdentifiers",
- "responses": {"200": {
- "description": "Information type identifiers",
- "content": {"application/json": {"schema": {
- "type": "array",
- "items": {"type": "string"}
- }}}
- }},
- "tags": ["Data consumer"]
- }},
"/data-producer/v1/info-producers/{infoProducerId}": {
"get": {
"summary": "Individual Information Producer",
"tags": ["A1-EI (registration)"]
}
},
- "/data-consumer/v1/info-jobs": {"get": {
- "summary": "Information Job identifiers",
- "description": "query for information job identifiers",
- "operationId": "getJobIds",
- "responses": {
- "200": {
- "description": "Information information job identifiers",
- "content": {"application/json": {"schema": {
- "type": "array",
- "items": {"type": "string"}
- }}}
- },
- "404": {
- "description": "Information type is not found",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
- }
- },
- "parameters": [
- {
- "schema": {"type": "string"},
- "in": "query",
- "name": "infoTypeId",
- "description": "selects subscription jobs of matching information type",
- "required": false
- },
- {
- "schema": {"type": "string"},
- "in": "query",
- "name": "owner",
- "description": "selects result for one owner",
- "required": false
- }
- ],
- "tags": ["Data consumer"]
+ "/actuator/logfile": {"get": {
+ "summary": "Actuator web endpoint 'logfile'",
+ "operationId": "handle_8",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "tags": ["Actuator"]
}},
"/data-consumer/v1/info-jobs/{infoJobId}": {
"get": {
}],
"tags": ["Data consumer"]
}},
- "/example_dataconsumer/info_jobs/{infoJobId}/status": {"post": {
- "summary": "Callback for changed Information Job status",
- "requestBody": {
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/EiJobStatusObject"}}},
- "required": true
- },
- "description": "The primitive is implemented by the data consumer and is invoked when a Information Job status has been changed.",
- "operationId": "jobStatusCallback",
+ "/actuator/health": {"get": {
+ "summary": "Actuator web endpoint 'health'",
+ "operationId": "handle_11",
"responses": {"200": {
"description": "OK",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/Void"}}}
+ "content": {"*/*": {"schema": {"type": "object"}}}
}},
- "parameters": [{
- "schema": {"type": "string"},
- "in": "path",
- "name": "infoJobId",
- "required": true
- }],
- "tags": ["A1-EI (callbacks)"]
+ "tags": ["Actuator"]
}},
"/A1-EI/v1/eijobs": {"get": {
"summary": "EI job identifiers",
],
"tags": ["A1-EI (registration)"]
}},
- "/A1-EI/v1/eijobs/{eiJobId}/status": {"get": {
- "summary": "EI job status",
- "operationId": "getEiJobStatus_1",
- "responses": {
- "200": {
- "description": "EI job status",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/EiJobStatusObject"}}}
- },
- "404": {
- "description": "Enrichment Information job is not found",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
- }
- },
- "parameters": [{
- "schema": {"type": "string"},
- "in": "path",
- "name": "eiJobId",
- "required": true
- }],
- "tags": ["A1-EI (registration)"]
- }},
- "/data-producer/v1/info-producers/{infoProducerId}/status": {"get": {
- "summary": "Information producer status",
- "operationId": "getInfoProducerStatus",
- "responses": {
- "200": {
- "description": "Information producer status",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/producer_status"}}}
- },
- "404": {
- "description": "Information producer is not found",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
- }
- },
- "parameters": [{
- "schema": {"type": "string"},
- "in": "path",
- "name": "infoProducerId",
- "required": true
- }],
- "tags": ["Data producer (registration)"]
- }},
"/data-producer/v1/info-producers/{infoProducerId}/info-jobs": {"get": {
"summary": "Information Job definitions",
"description": "Information Job definitions for one Information Producer",
}],
"tags": ["Data producer (registration)"]
}},
- "/data-consumer/v1/info-jobs/{infoJobId}/status": {"get": {
- "summary": "Job status",
- "operationId": "getEiJobStatus",
- "responses": {
- "200": {
- "description": "Information subscription job status",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/consumer_job_status"}}}
- },
- "404": {
- "description": "Information subscription job is not found",
- "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProblemDetails"}}}
- }
- },
- "parameters": [{
- "schema": {"type": "string"},
- "in": "path",
- "name": "infoJobId",
- "required": true
- }],
- "tags": ["Data consumer"]
- }},
"/example_dataconsumer/info_type_status": {"post": {
"summary": "Callback for changed Information type registration status",
"requestBody": {
"content": {"application/json": {"schema": {"$ref": "#/components/schemas/Void"}}}
}},
"tags": ["Data consumer (callbacks)"]
+ }},
+ "/actuator/heapdump": {"get": {
+ "summary": "Actuator web endpoint 'heapdump'",
+ "operationId": "handle_10",
+ "responses": {"200": {
+ "description": "OK",
+ "content": {"*/*": {"schema": {"type": "object"}}}
+ }},
+ "tags": ["Actuator"]
}}
},
"info": {
{
"name": "Data consumer",
"description": "API for data consumers"
+ },
+ {
+ "name": "Actuator",
+ "description": "Monitor and interact",
+ "externalDocs": {
+ "description": "Spring Boot Actuator Web API Documentation",
+ "url": "https://docs.spring.io/spring-boot/docs/current/actuator-api/html/"
+ }
}
]
}
\ No newline at end of file
description: API for monitoring of the service
- name: Data consumer
description: API for data consumers
+- name: Actuator
+ description: Monitor and interact
+ externalDocs:
+ description: Spring Boot Actuator Web API Documentation
+ url: https://docs.spring.io/spring-boot/docs/current/actuator-api/html/
paths:
/example_dataproducer/info_job/{infoJobId}:
delete:
application/json:
schema:
$ref: '#/components/schemas/ProblemDetails'
+ /actuator/threaddump:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'threaddump'
+ operationId: handle_2_1_3
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
/example_dataproducer/info_job:
post:
tags:
application/json:
schema:
$ref: '#/components/schemas/ProblemDetails'
+ /actuator/loggers:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'loggers'
+ operationId: handle_6
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
+ /actuator/health/**:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'health-path'
+ operationId: handle_12
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
+ /data-consumer/v1/info-types:
+ get:
+ tags:
+ - Data consumer
+ summary: Information type identifiers
+ operationId: getinfoTypeIdentifiers
+ responses:
+ 200:
+ description: Information type identifiers
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ type: string
+ /actuator/metrics/{requiredMetricName}:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'metrics-requiredMetricName'
+ operationId: handle_5
+ parameters:
+ - name: requiredMetricName
+ in: path
+ required: true
+ style: simple
+ explode: false
+ schema:
+ type: string
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
+ /actuator:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator root web endpoint
+ operationId: links_1
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
+ additionalProperties:
+ type: object
+ additionalProperties:
+ $ref: '#/components/schemas/Link'
+ /data-consumer/v1/info-jobs:
+ get:
+ tags:
+ - Data consumer
+ summary: Information Job identifiers
+ description: query for information job identifiers
+ operationId: getJobIds
+ parameters:
+ - name: infoTypeId
+ in: query
+ description: selects subscription jobs of matching information type
+ required: false
+ style: form
+ explode: true
+ schema:
+ type: string
+ - name: owner
+ in: query
+ description: selects result for one owner
+ required: false
+ style: form
+ explode: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: Information information job identifiers
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ type: string
+ 404:
+ description: Information type is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ /actuator/loggers/{name}:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'loggers-name'
+ operationId: handle_7
+ parameters:
+ - name: name
+ in: path
+ required: true
+ style: simple
+ explode: false
+ schema:
+ type: string
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
+ post:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'loggers-name'
+ operationId: handle_0
+ parameters:
+ - name: name
+ in: path
+ required: true
+ style: simple
+ explode: false
+ schema:
+ type: string
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
+ /example_dataconsumer/info_jobs/{infoJobId}/status:
+ post:
+ tags:
+ - A1-EI (callbacks)
+ summary: Callback for changed Information Job status
+ description: The primitive is implemented by the data consumer and is invoked
+ when a Information Job status has been changed.
+ operationId: jobStatusCallback
+ parameters:
+ - name: infoJobId
+ in: path
+ required: true
+ style: simple
+ explode: false
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/EiJobStatusObject'
+ required: true
+ responses:
+ 200:
+ description: OK
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/Void'
+ /A1-EI/v1/eijobs/{eiJobId}/status:
+ get:
+ tags:
+ - A1-EI (registration)
+ summary: EI job status
+ operationId: getEiJobStatus_1
+ parameters:
+ - name: eiJobId
+ in: path
+ required: true
+ style: simple
+ explode: false
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI job status
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/EiJobStatusObject'
+ 404:
+ description: Enrichment Information job is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ /data-producer/v1/info-producers/{infoProducerId}/status:
+ get:
+ tags:
+ - Data producer (registration)
+ summary: Information producer status
+ operationId: getInfoProducerStatus
+ parameters:
+ - name: infoProducerId
+ in: path
+ required: true
+ style: simple
+ explode: false
+ schema:
+ type: string
+ responses:
+ 200:
+ description: Information producer status
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/producer_status'
+ 404:
+ description: Information producer is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ /data-consumer/v1/info-jobs/{infoJobId}/status:
+ get:
+ tags:
+ - Data consumer
+ summary: Job status
+ operationId: getEiJobStatus
+ parameters:
+ - name: infoJobId
+ in: path
+ required: true
+ style: simple
+ explode: false
+ schema:
+ type: string
+ responses:
+ 200:
+ description: Information subscription job status
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/consumer_job_status'
+ 404:
+ description: Information subscription job is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ /actuator/metrics:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'metrics'
+ operationId: handle_4
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
+ /actuator/info:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'info'
+ operationId: handle_9
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
/example_dataproducer/health_check:
get:
tags:
type: array
items:
type: string
- /data-consumer/v1/info-types:
- get:
- tags:
- - Data consumer
- summary: Information type identifiers
- operationId: getinfoTypeIdentifiers
- responses:
- 200:
- description: Information type identifiers
- content:
- application/json:
- schema:
- type: array
- items:
- type: string
/data-producer/v1/info-producers/{infoProducerId}:
get:
tags:
application/json:
schema:
$ref: '#/components/schemas/ProblemDetails'
- /data-consumer/v1/info-jobs:
+ /actuator/logfile:
get:
tags:
- - Data consumer
- summary: Information Job identifiers
- description: query for information job identifiers
- operationId: getJobIds
- parameters:
- - name: infoTypeId
- in: query
- description: selects subscription jobs of matching information type
- required: false
- style: form
- explode: true
- schema:
- type: string
- - name: owner
- in: query
- description: selects result for one owner
- required: false
- style: form
- explode: true
- schema:
- type: string
+ - Actuator
+ summary: Actuator web endpoint 'logfile'
+ operationId: handle_8
responses:
200:
- description: Information information job identifiers
- content:
- application/json:
- schema:
- type: array
- items:
- type: string
- 404:
- description: Information type is not found
+ description: OK
content:
- application/json:
+ '*/*':
schema:
- $ref: '#/components/schemas/ProblemDetails'
+ type: object
/data-consumer/v1/info-jobs/{infoJobId}:
get:
tags:
application/json:
schema:
$ref: '#/components/schemas/ProblemDetails'
- /example_dataconsumer/info_jobs/{infoJobId}/status:
- post:
+ /actuator/health:
+ get:
tags:
- - A1-EI (callbacks)
- summary: Callback for changed Information Job status
- description: The primitive is implemented by the data consumer and is invoked
- when a Information Job status has been changed.
- operationId: jobStatusCallback
- parameters:
- - name: infoJobId
- in: path
- required: true
- style: simple
- explode: false
- schema:
- type: string
- requestBody:
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/EiJobStatusObject'
- required: true
+ - Actuator
+ summary: Actuator web endpoint 'health'
+ operationId: handle_11
responses:
200:
description: OK
content:
- application/json:
+ '*/*':
schema:
- $ref: '#/components/schemas/Void'
+ type: object
/A1-EI/v1/eijobs:
get:
tags:
application/json:
schema:
$ref: '#/components/schemas/ProblemDetails'
- /A1-EI/v1/eijobs/{eiJobId}/status:
- get:
- tags:
- - A1-EI (registration)
- summary: EI job status
- operationId: getEiJobStatus_1
- parameters:
- - name: eiJobId
- in: path
- required: true
- style: simple
- explode: false
- schema:
- type: string
- responses:
- 200:
- description: EI job status
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/EiJobStatusObject'
- 404:
- description: Enrichment Information job is not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ProblemDetails'
- /data-producer/v1/info-producers/{infoProducerId}/status:
- get:
- tags:
- - Data producer (registration)
- summary: Information producer status
- operationId: getInfoProducerStatus
- parameters:
- - name: infoProducerId
- in: path
- required: true
- style: simple
- explode: false
- schema:
- type: string
- responses:
- 200:
- description: Information producer status
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/producer_status'
- 404:
- description: Information producer is not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ProblemDetails'
/data-producer/v1/info-producers/{infoProducerId}/info-jobs:
get:
tags:
application/json:
schema:
$ref: '#/components/schemas/ProblemDetails'
- /data-consumer/v1/info-jobs/{infoJobId}/status:
- get:
- tags:
- - Data consumer
- summary: Job status
- operationId: getEiJobStatus
- parameters:
- - name: infoJobId
- in: path
- required: true
- style: simple
- explode: false
- schema:
- type: string
- responses:
- 200:
- description: Information subscription job status
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/consumer_job_status'
- 404:
- description: Information subscription job is not found
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/ProblemDetails'
/example_dataconsumer/info_type_status:
post:
tags:
application/json:
schema:
$ref: '#/components/schemas/Void'
+ /actuator/heapdump:
+ get:
+ tags:
+ - Actuator
+ summary: Actuator web endpoint 'heapdump'
+ operationId: handle_10
+ responses:
+ 200:
+ description: OK
+ content:
+ '*/*':
+ schema:
+ type: object
components:
schemas:
consumer_information_type:
Void:
type: object
description: 'Void/empty '
+ Link:
+ type: object
+ properties:
+ templated:
+ type: boolean
+ href:
+ type: string
consumer_type_subscription_info:
required:
- owner
allow-bean-definition-overriding: true
aop:
auto: false
+springdoc:
+ show-actuator: true
management:
endpoints:
web:
<sonar-maven-plugin.version>3.7.0.1746</sonar-maven-plugin.version>
</properties>
<modules>
- <module>policy-agent</module>
+ <module>a1-policy-management-service</module>
<module>information-coordinator-service</module>
<module>r-app-catalogue</module>
<module>helm-manager</module>
<module>dmaap-adaptor-java</module>
+ <module>dmaap-mediator-producer</module>
</modules>
<build>
<plugins>
ADD target/${JAR} /opt/app/r-app-catalogue/r-app-catalogue.jar
-RUN chmod -R 777 /opt/app/r-app-catalogue/config/
+RUN chmod -R 644 /opt/app/r-app-catalogue/config/
+
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+RUN chown -R appuser:appuser /opt/app/r-app-catalogue/
+RUN chown -R appuser:appuser /var/log/r-app-catalogue/
+USER appuser
CMD ["java", "-jar", "/opt/app/r-app-catalogue/r-app-catalogue.jar"]
RUN chmod +x start.sh
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+USER appuser
+
CMD [ "./start.sh" ]
WORKDIR /usr/src/app
COPY http_proxy.js .
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+USER appuser
+
CMD [ "node", "http_proxy.js" ]
\ No newline at end of file
RUN chmod +x start.sh
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+USER appuser
+
CMD [ "./start.sh" ]
\ No newline at end of file
RUN apt-get update
RUN apt-get install -y nginx=1.14.*
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+USER appuser
+
CMD [ "./start.sh" ]
RUN pip install -r requirements.txt
+RUN groupadd -g 999 appuser && \
+ useradd -r -u 999 -g appuser appuser
+USER appuser
+
CMD [ "python3", "-u", "main.py" ]