From 56e2fa6af82b869ec9e8e3765fd746524bcfb5b6 Mon Sep 17 00:00:00 2001 From: Aytac Ozkan Date: Fri, 17 Apr 2020 13:38:55 +0200 Subject: [PATCH] bug fixings* --- .metals/metals.h2.db | Bin 0 -> 118784 bytes .metals/metals.log | 12 ++++++ data.sql | 100 ++++++++++++++++++++++--------------------- docker-compose.yml | 5 +++ 4 files changed, 68 insertions(+), 49 deletions(-) create mode 100644 .metals/metals.h2.db create mode 100644 .metals/metals.log diff --git a/.metals/metals.h2.db b/.metals/metals.h2.db new file mode 100644 index 0000000000000000000000000000000000000000..7d9ebef2fe4609bcd21adbd592b67f3043b8c355 GIT binary patch literal 118784 zcmeI*Urbxq9S3j&HxL|b$KU`VlpJ43z^Oxw4J1~pYS;DwZsR}1_nL%h)15KS$_h=3 zNn5r~)Bf~j4{cRx)3i>Lx~|f+P3qK#Y1*HcJx)_qt?$#`+U{kls&0Lll>P4YwS8@_ z!BvP!)^DUJfphQq{qE=d&gGtCFc&Yfr7#Ok&s~bKix-)b{_gv+!*SBl)#bn+2tWV= z5P$##AOHafKmY;|fB*y@Ac5%5{`!uY?o0G<_XCtVQiT8nAOHafKmY;|fB*y_009U< zphW?!|67E@VGw`-1Rwwb2tWV=5P$##AOL{}SfJY(xpU_ZzM=mC9zvuJ0SG_<0uX=z z1Rwwb2tWV=5I9i4yYrEL4DA8j@pL;*cX2v1?-O`ZTKkV*2?Rx)=>n{(v-a6}gg}H9~U0)n`J#x;)4h)S0 zAOHafKmY;|fB*y_009WxR|3L>Ul=>Ll37>?hJwN1&i3tM@MeCqRODenq^9#WO>#Im z6ATH=FN{puH1m*fmd>2AYYGcvOc)E;G|3_AG%So#r$L)$J|m1UVdSDs(;}TI4Eu$l zX`4n$W{3$xmu#BMh=WWR6izm8KgEPog1345fM4hr`fb`NbU&lE0h=}>XRm)+@Yyu- z=q3L&yKaujx^+-O(`;HeWpmDTgD)5f&Iad#^TEr(E5Yc){tHcdxxg+6gEqaCNdo@! z!jMht;%q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zNY|apwF;z*OrNLSRom0)n!$7T~?Ra42$t(CcUWW z*Ji9xgws@8FE+Uc#g{S)PnQ=eM44UTbZc)|LDq)ZGSi}TN3qmND^*6P2*Xrnxt7aJ z4^lUi?b5B(+Yr^;OSWr4%LUk6uDJlT9WZk+6}s2ORk}@9gv?g~%;xJ$M409AOg5o! zQB}7{X}AX|sqY?;R6@9p$hc7p&!@V!Tv{r=;MY#6` zoBdyjh>F4hRpeJ%ugHdi+?zM;+U$ANDBv45e*S;-2%hW^5&{r_00bZa0SG_<0uX=z z1Rwx`HVJq~ji3J?>1G!J-Nw)V541lrB0>NH5P$##AOHafKmY;|fB*y_&@KUQr}6rKKi>bp zUE+uX0SG_<0uX=z1Rwwb2tWV=5NN-EFZKsLsMjHQKJk3)`N;FH_UC|z5P$##AOHaf zKmY;|fB*y_009Ubsz8_2DRoG9Dt|g8?^oZ~1Gt?Iq4LQ)9iBgRc)r!?d8EtJaj4PJ z83Z5z0SG_<0uX=z1Rwwb2teSd1jczJ^LT!nm3Ft*Zf%wpm21iCD-lhj&uQl8rc2Lk z#=iZ--@V$kphzd)dGGz#e>Cj~NFoobN^$$y;x=2~C>3tee|GiLzqAt8v~q)1Z7}+H zoeB>Jx3KEaUlQ!2tWV=5P$##AOHafKmY;|xc36yoi{f@5KB6wL=>*AOHafKmY;|fB*y_009U<00KuN&^gvu2|VG@f7{;) i`s?hkd=CFY00Izz00bZa0SG_<0uX=z1R(H#An-qkOQ_fY literal 0 HcmV?d00001 diff --git a/.metals/metals.log b/.metals/metals.log new file mode 100644 index 0000000..3ff59a5 --- /dev/null +++ b/.metals/metals.log @@ -0,0 +1,12 @@ +INFO started: Metals version 0.8.4 in workspace '/home/magnusanatolius/works/in-sylva.infrastructure' +INFO time: initialize in 0.34s +WARN no build tool detected in workspace '/home/magnusanatolius/works/in-sylva.infrastructure'. The most common cause for this problem is that the editor was opened in the wrong working directory, for example if you use sbt then the workspace directory should contain build.sbt. +Apr 16, 2020 7:22:58 PM org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint notify +INFO: Unsupported notification method: $/setTraceNotification +Apr 16, 2020 7:22:59 PM org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint notify +INFO: Unsupported notification method: $/setTraceNotification +Apr 16, 2020 7:23:04 PM org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint notify +INFO: Unsupported notification method: $/setTraceNotification +Apr 16, 2020 7:23:04 PM org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint notify +INFO: Unsupported notification method: $/setTraceNotification +INFO shutting down Metals diff --git a/data.sql b/data.sql index 7a8caf4..3a52f6e 100644 --- a/data.sql +++ b/data.sql @@ -13,7 +13,7 @@ CREATE TABLE IF NOT EXISTS users ( CREATE TABLE IF NOT EXISTS sources ( id serial PRIMARY KEY, - index_id varchar(50) NOT NULL, + index_id varchar(50), mng_id varchar(50) NOT NULL, name varchar(50) NOT NULL , description text, @@ -23,54 +23,6 @@ CREATE TABLE IF NOT EXISTS sources ( update_at timestamp ); -create unique index sources_name_uindex - on sources (name); - -CREATE TABLE IF NOT EXISTS user_profile ( - id serial PRIMARY KEY, - profil_name varchar(100), - kc_id varchar(100), - - CONSTRAINT user_profile_kc_id FOREIGN KEY (kc_id) - REFERENCES users(kc_id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, - - create_at timestamp NOT NULL DEFAULT NOW(), - update_at timestamp -); - -CREATE TABLE IF NOT EXISTS field_specifications ( - id serial PRIMARY KEY, - std_field_id int, - addtl_field_id int, - kc_id varchar(100), - - CONSTRAINT field_specifications_std_field_id FOREIGN KEY (std_field_id) - REFERENCES std_fields(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, - - CONSTRAINT field_specifications_addtl_field_id FOREIGN KEY (addtl_field_id) - REFERENCES addtl_fields(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, - - CONSTRAINT field_specifications_kc_id FOREIGN KEY (kc_id) - REFERENCES users(kc_id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, - - create_at timestamp NOT NULL DEFAULT NOW(), - update_at timestamp -); - -CREATE TABLE IF NOT EXISTS profile_specifications( - profil_id int, - field_specification_id int, - - CONSTRAINT profile_specifications_profil_id FOREIGN KEY (profil_id) - REFERENCES user_profile(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, - - CONSTRAINT field_specifications_field_specification_id FOREIGN KEY (field_specification_id) - REFERENCES field_specifications(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, - - create_at timestamp NOT NULL DEFAULT NOW(), - update_at timestamp -); - CREATE table IF NOT EXISTS provider_sources ( id serial PRIMARY KEY, user_id integer NOT NULL, @@ -263,6 +215,56 @@ CREATE table IF NOT EXISTS user_search_his( create_at timestamp NOT NULL DEFAULT NOW(), update_at timestamp ); + +create unique index sources_name_uindex + on sources (name); + +CREATE TABLE IF NOT EXISTS user_profile ( + id serial PRIMARY KEY, + profil_name varchar(100), + kc_id varchar(100), + + CONSTRAINT user_profile_kc_id FOREIGN KEY (kc_id) + REFERENCES users(kc_id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, + + create_at timestamp NOT NULL DEFAULT NOW(), + update_at timestamp +); + +CREATE TABLE IF NOT EXISTS field_specifications ( + id serial PRIMARY KEY, + std_field_id int, + addtl_field_id int, + kc_id varchar(100), + + CONSTRAINT field_specifications_std_field_id FOREIGN KEY (std_field_id) + REFERENCES std_fields(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, + + CONSTRAINT field_specifications_addtl_field_id FOREIGN KEY (addtl_field_id) + REFERENCES addtl_fields(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, + + CONSTRAINT field_specifications_kc_id FOREIGN KEY (kc_id) + REFERENCES users(kc_id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, + + create_at timestamp NOT NULL DEFAULT NOW(), + update_at timestamp +); + +CREATE TABLE IF NOT EXISTS profile_specifications( + profil_id int, + field_specification_id int, + + CONSTRAINT profile_specifications_profil_id FOREIGN KEY (profil_id) + REFERENCES user_profile(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, + + CONSTRAINT field_specifications_field_specification_id FOREIGN KEY (field_specification_id) + REFERENCES field_specifications(id) MATCH SIMPLE ON UPDATE NO ACTION ON DELETE NO ACTION, + + create_at timestamp NOT NULL DEFAULT NOW(), + update_at timestamp +); + + /* CREATE OR REPLACE FUNCTION func_role_updater() RETURNS TRIGGER AS $BODY$ BEGIN diff --git a/docker-compose.yml b/docker-compose.yml index de9ed54..b2d8433 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -230,6 +230,10 @@ services: ELK_USERNAME: admin ELK_PASSWORD: InSylva146544 + KEYCLOAK_REALM: "in-sylva" + SERVER_URL: http://keycloak:8080/keycloak/auth + CLIENT_ID: "in-sylva.user.app" + PORT: 5000 ports: - 5000:5000 @@ -237,6 +241,7 @@ services: - mongo - postgres - odfe-node1 + - keycloak networks: - app-network restart: unless-stopped