summaryrefslogtreecommitdiffstats
path: root/extra/sql/bulkload
diff options
context:
space:
mode:
authorxuegao <xg353y@intl.att.com>2019-11-08 13:10:36 +0100
committerxuegao <xg353y@intl.att.com>2019-11-18 10:41:47 +0100
commit289e8e1f1858e970f92b50a1e601521edeefd44f (patch)
tree78246ad3b62c744626811949aea653d0ee7c8e58 /extra/sql/bulkload
parent77b0be1b734ae1f785fb35a59387ac5fbcf19266 (diff)
Create Service object
User Service object to store loop service and resource realted info. Issue-ID: CLAMP-545 Change-Id: I0df6f5d43d7e0575346e02a27bca5c0b5ecdb0a0 Signed-off-by: xuegao <xg353y@intl.att.com>
Diffstat (limited to 'extra/sql/bulkload')
-rw-r--r--extra/sql/bulkload/create-tables.sql15
1 files changed, 14 insertions, 1 deletions
diff --git a/extra/sql/bulkload/create-tables.sql b/extra/sql/bulkload/create-tables.sql
index 0e15d4d3a..dafd80034 100644
--- a/extra/sql/bulkload/create-tables.sql
+++ b/extra/sql/bulkload/create-tables.sql
@@ -23,9 +23,9 @@
dcae_deployment_status_url varchar(255),
global_properties_json json,
last_computed_state varchar(255) not null,
- model_properties_json json,
operational_policy_schema json,
svg_representation MEDIUMTEXT,
+ service_uuid varchar(255),
primary key (name)
) engine=InnoDB;
@@ -52,11 +52,24 @@
primary key (name)
) engine=InnoDB;
+ create table services (
+ service_uuid varchar(255) not null,
+ name varchar(255) not null,
+ resource_details json,
+ service_details json,
+ primary key (service_uuid)
+ ) engine=InnoDB;
+
alter table loop_logs
add constraint FK1j0cda46aickcaoxqoo34khg2
foreign key (loop_id)
references loops (name);
+ alter table loops
+ add constraint FK4b9wnqopxogwek014i1shqw7w
+ foreign key (service_uuid)
+ references services (service_uuid);
+
alter table loops_microservicepolicies
add constraint FKem7tp1cdlpwe28av7ef91j1yl
foreign key (microservicepolicy_id)