Changeset 7409


Ignore:
Timestamp:
01/09/10 12:15:14 (9 years ago)
Author:
mnagni
Message:

Update of the tables underlying the DPWS's BETA-0.0.1 version

Location:
TI01-discovery-Ingest/trunk/v4.3.0/ingestAutomation-upgrade/ingestLoggingDatabase
Files:
8 added
2 deleted
5 edited

Legend:

Unmodified
Added
Removed
  • TI01-discovery-Ingest/trunk/v4.3.0/ingestAutomation-upgrade/ingestLoggingDatabase/HarvestLog.sql

    r7241 r7409  
    1 -- Table: "HarvestLog" 
     1-- Table: harvest_log 
    22 
    3 DROP TABLE "HarvestLog"; 
     3-- DROP TABLE harvest_log; 
    44 
    5 CREATE TABLE "HarvestLog" 
     5CREATE TABLE harvest_log 
    66( 
    7   "newRecs" smallint, 
    8   "delRecs" smallint, 
    9   "updateRecs" smallint, 
    10   "startHarvest" timestamp without time zone, 
    11   "stopHarvest" timestamp without time zone, 
    12   "providerID" character varying, 
    13   "reqID" integer NOT NULL, 
    14   "totRecs" integer, 
    15   CONSTRAINT "redID_key" PRIMARY KEY ("reqID") 
     7  start_harvest timestamp without time zone, 
     8  stop_harvest timestamp without time zone, 
     9  req_id integer NOT NULL, 
     10  tot_recs integer, 
     11  CONSTRAINT "redID_key" PRIMARY KEY (req_id) 
    1612) 
    1713WITH ( 
    1814  OIDS=FALSE 
    1915); 
    20 ALTER TABLE "HarvestLog" OWNER TO badc; 
     16ALTER TABLE harvest_log OWNER TO badc; 
  • TI01-discovery-Ingest/trunk/v4.3.0/ingestAutomation-upgrade/ingestLoggingDatabase/OAIProvider.sql

    r7241 r7409  
    1 -- Table: "OAIProvider" 
     1-- Table: oai_provider 
    22 
    3 DROP TABLE "OAIProvider"; 
     3-- DROP TABLE oai_provider; 
    44 
    5 CREATE TABLE "OAIProvider" 
     5CREATE TABLE oai_provider 
    66( 
    7   "ID" integer NOT NULL, 
    8   "baseURL" character varying, 
    97  "set" character varying, 
    10   "formatID" smallint, 
    11   "splitBySet" boolean DEFAULT false, 
    12   CONSTRAINT frgn_key_format FOREIGN KEY ("formatID") 
    13       REFERENCES format ("ID") MATCH SIMPLE 
     8  split_by_set boolean DEFAULT false, 
     9  format character varying, 
     10  common_id integer NOT NULL DEFAULT -1, 
     11  CONSTRAINT oai_provider_pkey PRIMARY KEY (common_id), 
     12  CONSTRAINT oai_provider_common_id_fkey FOREIGN KEY (common_id) 
     13      REFERENCES provider_common (id) MATCH SIMPLE 
    1414      ON UPDATE NO ACTION ON DELETE NO ACTION 
    1515) 
     
    1717  OIDS=FALSE 
    1818); 
    19 ALTER TABLE "OAIProvider" OWNER TO badc; 
     19ALTER TABLE oai_provider OWNER TO badc; 
     20 
     21INSERT INTO oai_provider (set, split_by_set, format, common_id) VALUES (NULL, true, 'dif', -1); 
  • TI01-discovery-Ingest/trunk/v4.3.0/ingestAutomation-upgrade/ingestLoggingDatabase/create_database.sh

    r7297 r7409  
    2727psql -f IngestLoggingTable.sql $dbOptions 
    2828psql -f IngestProblemFileTable.sql $dbOptions 
     29#psql -f GeneratorTable.sql $dbOptions 
     30#psql -f HiProcess.sql $dbOptions 
     31#psql -f HiStatus.sql $dbOptions 
     32#psql -f provider.sql $dbOptions 
     33#psql -f OAIProvider.sql $dbOptions 
     34#psql -f CSWProvider.sql $dbOptions 
     35#psql -f ProviderEmails.sql $dbOptions 
     36#psql -f ServiceParameter.sql $dbOptions 
     37#psql -f ServiceParameterValue.sql $dbOptions 
     38#psql -f Roles.sql $dbOptions 
    2939#psql -f HarvestLog.sql $dbOptions 
    30 #psql -f HarvestType.sql $dbOptions 
    31 #psql -f formatTable.sql $dbOptions 
    32 #psql -f OAIProvider.sql $dbOptions 
    33 #psql -f provider.sql $dbOptions 
    3440#psql -f service_config.sql $dbOptions 
    3541 
  • TI01-discovery-Ingest/trunk/v4.3.0/ingestAutomation-upgrade/ingestLoggingDatabase/provider.sql

    r7241 r7409  
    1 -- 
    2 -- PostgreSQL database dump 
    3 -- 
     1-- Table: provider_common 
    42 
    5 -- Started on 2010-07-21 16:22:12 BST 
     3-- DROP TABLE provider_common; 
    64 
    7 DROP TABLE "provider"; 
     5CREATE TABLE provider_common 
     6( 
     7  id integer NOT NULL, 
     8  base_url character varying, 
     9  email_to_admin boolean, 
     10  "name" character varying, 
     11  CONSTRAINT provider_common_pkey PRIMARY KEY (id) 
     12) 
     13WITH ( 
     14  OIDS=FALSE 
     15); 
     16ALTER TABLE provider_common OWNER TO badc; 
    817 
    9 SET statement_timeout = 0; 
    10 SET client_encoding = 'UTF8'; 
    11 SET standard_conforming_strings = off; 
    12 SET check_function_bodies = false; 
    13 SET client_min_messages = warning; 
    14 SET escape_string_warning = off; 
     18INSERT INTO provider_common (id, base_url, email_to_admin, name) VALUES (-1, 'http://neodc.nerc.ac.uk/neodc_oai/provider', true, 'OAIsample'); 
     19INSERT INTO provider_common (id, base_url, email_to_admin, name) VALUES (-2, 'http://gateway.ceh.ac.uk/soapServices/CSWStartup', true, 'CSWsample'); 
    1520 
    16 SET search_path = public, pg_catalog; 
    17  
    18 SET default_tablespace = ''; 
    19  
    20 SET default_with_oids = false; 
    21  
    22 -- 
    23 -- TOC entry 2205 (class 1259 OID 1161537) 
    24 -- Dependencies: 6 
    25 -- Name: provider; Type: TABLE; Schema: public; Owner: badc; Tablespace:  
    26 -- 
    27  
    28 CREATE TABLE provider ( 
    29     "ID" integer NOT NULL, 
    30     harvest_type_id smallint 
    31 ); 
    32  
    33  
    34 ALTER TABLE public.provider OWNER TO badc; 
    35  
    36 -- 
    37 -- TOC entry 2488 (class 0 OID 1161537) 
    38 -- Dependencies: 2205 
    39 -- Data for Name: provider; Type: TABLE DATA; Schema: public; Owner: badc 
    40 -- 
    41  
    42 INSERT INTO provider ("ID", harvest_type_id) VALUES (1, 1); 
    43  
    44  
    45 -- 
    46 -- TOC entry 2486 (class 2606 OID 1161541) 
    47 -- Dependencies: 2205 2205 
    48 -- Name: provider_pk; Type: CONSTRAINT; Schema: public; Owner: badc; Tablespace:  
    49 -- 
    50  
    51 ALTER TABLE ONLY provider 
    52     ADD CONSTRAINT provider_pk PRIMARY KEY ("ID"); 
    53  
    54  
    55 -- 
    56 -- TOC entry 2487 (class 2606 OID 1161542) 
    57 -- Dependencies: 2205 2204 
    58 -- Name: provider_ht_fk; Type: FK CONSTRAINT; Schema: public; Owner: badc 
    59 -- 
    60  
    61 ALTER TABLE ONLY provider 
    62     ADD CONSTRAINT provider_ht_fk FOREIGN KEY (harvest_type_id) REFERENCES "HarvestType"("ID"); 
    63  
    64  
    65 -- Completed on 2010-07-21 16:22:12 BST 
    66  
    67 -- 
    68 -- PostgreSQL database dump complete 
    69 -- 
    70  
  • TI01-discovery-Ingest/trunk/v4.3.0/ingestAutomation-upgrade/ingestLoggingDatabase/service_config.sql

    r7241 r7409  
    1 -- 
    2 -- PostgreSQL database dump 
    3 -- 
     1-- Table: service_config 
    42 
    5 -- Started on 2010-07-21 16:24:16 BST 
     3-- DROP TABLE service_config; 
    64 
    7 DROP TABLE "service_config"; 
     5CREATE TABLE service_config 
     6( 
     7  param_name character varying NOT NULL, 
     8  param_value character varying, 
     9  CONSTRAINT key_srv_param_name PRIMARY KEY (param_name) 
     10) 
     11WITH ( 
     12  OIDS=FALSE 
     13); 
     14ALTER TABLE service_config OWNER TO badc; 
    815 
    9 SET statement_timeout = 0; 
    10 SET client_encoding = 'UTF8'; 
    11 SET standard_conforming_strings = off; 
    12 SET check_function_bodies = false; 
    13 SET client_min_messages = warning; 
    14 SET escape_string_warning = off; 
     16INSERT INTO service_config (param_name, param_value) VALUES ('HARVEST_ROOT_PATH', '/toConfig'); 
     17INSERT INTO service_config (param_name, param_value) VALUES ('NEW_DISPATCHED_HARVEST_MAIL', 'A new request to harvest the provider ID:{0} has been submitted with processID:{1}'); 
     18INSERT INTO service_config (param_name, param_value) VALUES ('HARVEST_TERMINATED_MAIL', 'The harvest process associated with processID:{0} terminated succesfully'); 
     19INSERT INTO service_config (param_name, param_value) VALUES ('DO_INGEST_CMD', '/toConfig/python2.5.1 /toConfig/metadata_ingest/ingestAutomation-upgrade/OAIBatch/Metadata_document_ingester.py ingestProcessID={0}'); 
     20INSERT INTO service_config (param_name, param_value) VALUES ('NEW_DISPATCHED_INGEST_MAIL', 'A request to ingest the processID:{0} has been submitted'); 
     21INSERT INTO service_config (param_name, param_value) VALUES ('DO_INGEST_PROCESS_TERMINATED_EMAIL', 'The ingest process associated with processID:{0} terminated succesfully'); 
     22INSERT INTO service_config (param_name, param_value) VALUES ('PROCESS_FAILED_EMAIL', 'The process associated with processID:{0} has failed.  {1}'); 
    1523 
    16 SET search_path = public, pg_catalog; 
    17  
    18 SET default_tablespace = ''; 
    19  
    20 SET default_with_oids = false; 
    21  
    22 -- 
    23 -- TOC entry 2201 (class 1259 OID 1161494) 
    24 -- Dependencies: 6 
    25 -- Name: service_config; Type: TABLE; Schema: public; Owner: badc; Tablespace:  
    26 -- 
    27  
    28 CREATE TABLE service_config ( 
    29     param_name character varying NOT NULL, 
    30     param_value character varying 
    31 ); 
    32  
    33  
    34 ALTER TABLE public.service_config OWNER TO badc; 
    35  
    36 -- 
    37 -- TOC entry 2487 (class 0 OID 1161494) 
    38 -- Dependencies: 2201 
    39 -- Data for Name: service_config; Type: TABLE DATA; Schema: public; Owner: badc 
    40 -- 
    41  
    42 INSERT INTO service_config (param_name, param_value) VALUES ('HARVEST_ROOT_PATH', '/home/users/mnagni/toTrash/tmp'); 
    43  
    44  
    45 -- 
    46 -- TOC entry 2486 (class 2606 OID 1161501) 
    47 -- Dependencies: 2201 2201 
    48 -- Name: key_srv_param_name; Type: CONSTRAINT; Schema: public; Owner: badc; Tablespace:  
    49 -- 
    50  
    51 ALTER TABLE ONLY service_config 
    52     ADD CONSTRAINT key_srv_param_name PRIMARY KEY (param_name); 
    53  
    54  
    55 -- Completed on 2010-07-21 16:24:16 BST 
    56  
    57 -- 
    58 -- PostgreSQL database dump complete 
    59 -- 
    60  
Note: See TracChangeset for help on using the changeset viewer.