diff options
author | lizi00164331 <li.zi30@zte.com.cn> | 2017-08-07 11:04:17 +0800 |
---|---|---|
committer | lizi00164331 <li.zi30@zte.com.cn> | 2017-08-07 11:04:17 +0800 |
commit | aba957d99b0d0d21c77d80efe98a3450b6635c1a (patch) | |
tree | e8a5991c966560232d6215831ffe08324f5ff6a3 /esr-core/esr-mgr/src/test/resources | |
parent | 4bcebdf6c7a3cf81a77e1f2931db6d596923b866 (diff) |
Upload the ESR server seed code.
Issue-ID: AAI-67
Change-Id: Ie21ae7baebbb2ea8a35d8b51f75b7e21bcb78671
Signed-off-by: lizi00164331 <li.zi30@zte.com.cn>
Diffstat (limited to 'esr-core/esr-mgr/src/test/resources')
-rw-r--r-- | esr-core/esr-mgr/src/test/resources/Hibernate.cfg.xml | 38 | ||||
-rw-r--r-- | esr-core/esr-mgr/src/test/resources/db/extsys.mv.db | bin | 0 -> 12288 bytes | |||
-rw-r--r-- | esr-core/esr-mgr/src/test/resources/sql/extsys-resource-createObj-mysql.sql | 71 |
3 files changed, 109 insertions, 0 deletions
diff --git a/esr-core/esr-mgr/src/test/resources/Hibernate.cfg.xml b/esr-core/esr-mgr/src/test/resources/Hibernate.cfg.xml new file mode 100644 index 0000000..8d0776d --- /dev/null +++ b/esr-core/esr-mgr/src/test/resources/Hibernate.cfg.xml @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + + Copyright 2016 ZTE Corporation. + + 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. + +--> +<!DOCTYPE hibernate-configuration PUBLIC +"-//Hibernate/Hibernate Configuration DTD 3.0//EN" +"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd"> +<hibernate-configuration> +<session-factory> + <property name="show_sql">true</property> + <property name="dialect">org.hibernate.dialect.H2Dialect</property> + <property name="hibernate.connection.driver_class">org.h2.Driver</property> + <property name="hibernate.connection.url">jdbc:h2:tcp://localhost:18207/./db/extsys</property> + <property name="hibernate.connection.username">extsys</property> + <property name="hibernate.connection.password">extsys</property> + <property name="hbm2ddl">update</property> + <property name="current_session_context_class">thread</property> + <mapping class="org.onap.aai.esr.entity.db.EmsData"/> + <mapping class="org.onap.aai.esr.entity.db.BaseData"/> + <mapping class="org.onap.aai.esr.entity.db.SdncData"/> + <mapping class="org.onap.aai.esr.entity.db.VimData"/> + <mapping class="org.onap.aai.esr.entity.db.VnfmData"/> +</session-factory> +</hibernate-configuration> diff --git a/esr-core/esr-mgr/src/test/resources/db/extsys.mv.db b/esr-core/esr-mgr/src/test/resources/db/extsys.mv.db Binary files differnew file mode 100644 index 0000000..facfeac --- /dev/null +++ b/esr-core/esr-mgr/src/test/resources/db/extsys.mv.db diff --git a/esr-core/esr-mgr/src/test/resources/sql/extsys-resource-createObj-mysql.sql b/esr-core/esr-mgr/src/test/resources/sql/extsys-resource-createObj-mysql.sql new file mode 100644 index 0000000..073c73f --- /dev/null +++ b/esr-core/esr-mgr/src/test/resources/sql/extsys-resource-createObj-mysql.sql @@ -0,0 +1,71 @@ +-- +-- Copyright 2016 ZTE Corporation. +-- +-- 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. +-- + +DROP TABLE IF EXISTS extsys_base_table; +CREATE TABLE extsys_base_table ( + ID VARCHAR(200) NOT NULL, + NAME VARCHAR(200) NULL, + TYPE VARCHAR(200) NULL, + VENDOR VARCHAR(100) NULL, + VERSION VARCHAR(100) NULL, + DESCRIPTION VARCHAR(100) NULL, + CREATETIME VARCHAR(200) NULL, + CATAGORY VARCHAR(200) NULL, + CONSTRAINT extsys_base_table PRIMARY KEY(ID) +); +DROP TABLE IF EXISTS extsys_ems_table; +CREATE TABLE extsys_ems_table ( + EMSID VARCHAR(200) NOT NULL, + URL VARCHAR(100) NULL, + PRODUCTNAME VARCHAR(100) NULL, + USERNAME VARCHAR(100) NULL, + PASSWORD VARCHAR(100) NULL, + CONSTRAINT extsys_ems_table PRIMARY KEY(EMSID) +); + +DROP TABLE IF EXISTS extsys_sdnc_table; +CREATE TABLE extsys_sdnc_table ( + SDNCONTROLLERID VARCHAR(200) NOT NULL, + URL VARCHAR(100) NULL, + USERNAME VARCHAR(100) NULL, + PASSWORD VARCHAR(100) NULL, + PRODUCTNAME VARCHAR(100) NULL, + PROTOCOL VARCHAR(100) NULL, + CONSTRAINT extsys_sdnc_table PRIMARY KEY(SDNCONTROLLERID) +); + +DROP TABLE IF EXISTS extsys_vim_table; +CREATE TABLE extsys_vim_table ( + VIMID VARCHAR(200) NOT NULL, + URL VARCHAR(100) NULL, + USERNAME VARCHAR(100) NULL, + PASSWORD VARCHAR(100) NULL, + DOMAIN VARCHAR(100) NULL, + TENANT VARCHAR(100) NULL, + CONSTRAINT extsys_vim_table PRIMARY KEY(VIMID) +); + +DROP TABLE IF EXISTS extsys_vnfm_table; +CREATE TABLE extsys_vnfm_table ( + VNFMID VARCHAR(200) NOT NULL, + URL VARCHAR(200) NULL, + USERNAME VARCHAR(100) NULL, + PASSWORD VARCHAR(100) NULL, + VIMID VARCHAR(100) NULL, + CERTIFICATEURL VARCHAR(200) NULL, + CONSTRAINT extsys_vnfm_table PRIMARY KEY(VNFMID) +); + |