summaryrefslogtreecommitdiffstats
path: root/intentanalysis/src/test/resources/intentdb-test-init.sql
blob: 8c8ab53b540e54e8c0c2037c834dfa81564aadff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
/*
 Navicat Premium Data Transfer

 Source Server         : 1
 Source Server Type    : PostgreSQL
 Source Server Version : 100011
 Source Host           : localhost:5432
 Source Catalog        : exampledb
 Source Schema         : mec

 Target Server Type    : PostgreSQL
 Target Server Version : 100011
 File Encoding         : 65001

 Date: 30/12/2019 14:40:23
*/
//CREATE EXTENSION IF NOT EXISTS "uuid-ossp";

DROP TABLE IF EXISTS intent;
DROP TABLE IF EXISTS expectation;
DROP TABLE IF EXISTS expectation_object;
DROP TABLE IF EXISTS expectation_target;
DROP TABLE IF EXISTS context;
DROP TABLE IF EXISTS fulfilment_info;
DROP TABLE IF EXISTS condition;

create table if not exists intent
(
    intent_id   varchar(255) primary key,
    intent_name varchar(255)
);

create table if not exists expectation
(
    expectation_id   varchar(255) primary key,
    expectation_name varchar(255),
    expectation_type varchar(255),
    intent_id        varchar(255)
);

create table if not exists expectation_object
(
    object_id       varchar(255) DEFAULT random_uuid(),
    primary key (object_id),
    object_type     varchar(255),
    object_instance varchar(255),
    expectation_id  varchar(255)
);

create table if not exists expectation_target
(
    target_id      varchar(255) primary key,
    target_name    varchar(255),
    expectation_id varchar(255)
);

create table if not exists context
(
    context_id   varchar(255) primary key,
    context_name varchar(255),
    parent_id    varchar(255)
);

create table if not exists fulfilment_info
(
    fulfilment_info_id     varchar(255) primary key,
    fulfilment_info_status varchar(255),
    not_fulfilled_state    varchar(255),
    not_fulfilled_reason   varchar(255)
);

create table if not exists condition
(
    condition_id    varchar(255) primary key,
    condition_name  varchar(255),
    operator_type   varchar(255),
    condition_value varchar(255),
    parent_id       varchar(255)
);

create table if not exists intent_management_function_reg_info(
    imfr_info_id varchar(255) primary key,
    imfr_info_description varchar(255),
    support_area varchar(255),
    support_model varchar(255),
    support_interfaces varchar(255),
    handle_name varchar(255),
    intent_function_type varchar(255)
    );
epositoryLayout> <addParentPoms>false</addParentPoms> <copyPom>false</copyPom> <includeScope>runtime</includeScope> <excludeScope>provided</excludeScope> <excludeTransitive>true</excludeTransitive> </configuration> </execution> </executions> </plugin> </plugins> </build> <dependencies> <dependency> <groupId>org.onap.policy.drools-pdp</groupId> <artifactId>policy-core</artifactId> <version>${project.version}</version> <scope>provided</scope> </dependency> <dependency> <groupId>org.onap.policy.drools-pdp</groupId> <artifactId>policy-management</artifactId> <version>${project.version}</version> <scope>provided</scope> </dependency> <dependency> <groupId>org.onap.policy.common</groupId> <artifactId>utils</artifactId> <version>${project.version}</version> </dependency> <dependency> <groupId>org.powermock</groupId> <artifactId>powermock-api-mockito</artifactId> <version>${powermock.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.powermock</groupId> <artifactId>powermock-module-junit4</artifactId> <version>${powermock.version}</version> <scope>test</scope> <exclusions> <exclusion> <groupId>junit</groupId> <artifactId>junit</artifactId> </exclusion> <exclusion> <groupId>org.powermock</groupId> <artifactId>powermock-core</artifactId> </exclusion> <exclusion> <groupId>org.powermock</groupId> <artifactId>powermock-reflect</artifactId> </exclusion> <exclusion> <groupId>org.javassist</groupId> <artifactId>javassist</artifactId> </exclusion> </exclusions> </dependency> <dependency> <groupId>org.javassist</groupId> <artifactId>javassist</artifactId> <version>3.21.0-GA</version> <scope>test</scope> </dependency> <dependency> <groupId>org.jboss.jbossts</groupId> <artifactId>jbossjta</artifactId> <version>4.16.6.Final</version> <exclusions> <exclusion> <artifactId>jboss-servlet-api_3.0_spec</artifactId> <groupId>org.jboss.spec.javax.servlet</groupId> </exclusion> </exclusions> </dependency> <dependency> <groupId>com.h2database</groupId> <artifactId>h2</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.hibernate</groupId> <artifactId>hibernate-core</artifactId> <scope>provided</scope> </dependency> <dependency> <groupId>org.hibernate.common</groupId> <artifactId>hibernate-commons-annotations</artifactId> <scope>provided</scope> </dependency> <dependency> <groupId>org.apache.commons</groupId> <artifactId>commons-dbcp2</artifactId> <version>2.1.1</version> </dependency> <dependency> <groupId>org.apache.commons</groupId> <artifactId>commons-pool2</artifactId> <version>2.4.2</version> </dependency> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <scope>test</scope> </dependency> </dependencies> </project>