From ab400d51a639a01f31a60ac9d1e127d4d4d28b24 Mon Sep 17 00:00:00 2001 From: Reshmasree Date: Thu, 21 Mar 2019 18:54:53 +0530 Subject: Add component spec and blueprint - validated component spec and blueprints are added to the repo - pom file changed to build,tag and push the docker image - checkstyle version changed from 1.2.3-SNAPSHOT to 1.2.3 - entrypoint script added Change-Id: I0fcf8a17b0c5ce1990de506bf94d2d9ddf93d6fd Issue-ID: DCAEGEN2-1159 Signed-off-by: Reshmasree --- src/main/resources/application.properties | 9 ++++++--- src/main/resources/logback.xml | 2 +- src/main/resources/schema.sql | 27 +++++++++++++++++++++++++++ 3 files changed, 34 insertions(+), 4 deletions(-) create mode 100644 src/main/resources/schema.sql (limited to 'src/main/resources') diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 5905adf..c8bf90c 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -19,11 +19,14 @@ # ############################################################################### -spring.datasource.url= jdbc:postgresql://pcims-db:5432/sonh_ms -spring.datasource.username=postgres +spring.datasource.initialization-mode=always -spring.datasource.password=password +spring.datasource.initialize=true + +spring.datasource.schema=classpath:/schema.sql + +spring.datasource.continue-on-error=true spring.jpa.hibernate.ddl-auto=validate diff --git a/src/main/resources/logback.xml b/src/main/resources/logback.xml index 160ff9c..b7baa6f 100644 --- a/src/main/resources/logback.xml +++ b/src/main/resources/logback.xml @@ -28,7 +28,7 @@ - /var/log/onap/pci-handler/${logFileName}.log + /var/log/onap/son-handler/${logFileName}.log ${logFileName}.%i.log.zip 1 diff --git a/src/main/resources/schema.sql b/src/main/resources/schema.sql new file mode 100644 index 0000000..88b64d5 --- /dev/null +++ b/src/main/resources/schema.sql @@ -0,0 +1,27 @@ +CREATE TABLE DMAAP_NOTIFICATIONS( + notification TEXT PRIMARY KEY NOT NULL, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +CREATE TABLE BUFFERED_NOTIFICATIONS( + notification TEXT PRIMARY KEY NOT NULL, + cluster_id TEXT NOT NULL, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +CREATE TABLE CLUSTER_DETAILS( + cluster_id TEXT PRIMARY KEY NOT NULL, + cluster_info TEXT NOT NULL, + child_thread_id BIGINT UNIQUE NOT NULL +); +CREATE TABLE CELL_INFO( + cell_id TEXT PRIMARY KEY NOT NULL, + pnf_name TEXT NOT NULL +); +CREATE TABLE PCI_REQUESTS( + transaction_id TEXT PRIMARY KEY, + child_thread_id BIGINT UNIQUE NOT NULL +); +CREATE TABLE FAULT_NOTIFICATIONS( + notification TEXT PRIMARY KEY NOT NULL, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + -- cgit 1.2.3-korg