protected void |
OAuthSchemaGenerator.addCacheTable(PhysicalDataModel model) |
|
protected void |
OAuthSchemaGenerator.addClientConfigTable(PhysicalDataModel model) |
|
protected void |
FhirSchemaGenerator.addCodeSystems(PhysicalDataModel model) |
Add the code_systems table to the database schema
CREATE TABLE code_systems (
code_system_id INT NOT NULL
CONSTRAINT pk_code_system PRIMARY KEY,
code_system_name VARCHAR(255 OCTETS) NOT NULL
);
CREATE UNIQUE INDEX unq_code_system_cinm ON code_systems(code_system_name);
|
void |
FhirSchemaGenerator.addCommonCanonicalValues(PhysicalDataModel pdm) |
Create the COMMON_CANONICAL_VALUES table.
|
void |
FhirSchemaGenerator.addCommonTokenValues(PhysicalDataModel pdm) |
Adds the appropriate common_token_values table depending on the schema type
|
void |
FhirSchemaGenerator.addCommonTokenValuesDistributed(PhysicalDataModel pdm) |
The common_token_values definition used for the distributed (Citus) variant of the schema.
|
void |
FhirSchemaGenerator.addCommonTokenValuesStandard(PhysicalDataModel pdm) |
Table used to store normalized values for tokens, shared by all the
_TOKEN_VALUES tables.
|
protected void |
OAuthSchemaGenerator.addConsentCacheTable(PhysicalDataModel model) |
|
void |
FhirSchemaGenerator.addErasedResources(PhysicalDataModel pdm) |
The erased_resources table is used to track which logical resources and corresponding
resource versions have been erased using the $erase operation.
|
protected void |
FhirSchemaGenerator.addFhirChangeSequence(PhysicalDataModel pdm) |
Adds a new sequence required for distributed databases like Citus
|
protected void |
FhirSchemaGenerator.addFhirRefSequence(PhysicalDataModel pdm) |
|
protected void |
FhirSchemaGenerator.addFhirSequence(PhysicalDataModel pdm) |
CREATE SEQUENCE fhir_sequence
AS BIGINT
START WITH 1
CACHE 20000
NO CYCLE;
|
void |
JavaBatchSchemaGenerator.addGroupAssociationTable(PhysicalDataModel model) |
Adds the group association table with the following values:
CREATE TABLE FHIR_BATCH.GROUPASSOCIATION (
FK_JOBINSTANCEID BIGINT,
GROUPNAMES VARCHAR(255))
CREATE INDEX FHIR_BATCH.GA_FKINSTANCEID_IX ON FHIR_BATCH.GROUPASSOCIATION (FK_JOBINSTANCEID)
ALTER TABLE FHIR_BATCH.GROUPASSOCIATION ADD CONSTRAINT GRPSSCTNFKJBNSTNCD FOREIGN KEY (FK_JOBINSTANCEID)
REFERENCES FHIR_BATCH.JOBINSTANCE (JOBINSTANCEID)
|
void |
JavaBatchSchemaGenerator.addJobExecutionTable(PhysicalDataModel model) |
Adds the Job Execution table with the following values:
CREATE TABLE FHIR_BATCH.JOBEXECUTION(
JOBEXECID BIGINT GENERATED BY DEFAULT AS IDENTITY,
BATCHSTATUS INT NOT NULL,
CREATETIME TIMESTAMP NOT NULL,
ENDTIME TIMESTAMP,
EXECNUM INT NOT NULL,
EXITSTATUS VARCHAR(2048 OCTETS) NOT NULL,
JOBPARAMETERS BLOB(2147483647) INLINE LENGTH 10240,
UPDATETIME TIMESTAMP,
LOGPATH VARCHAR(512 OCTETS),
RESTURL VARCHAR(512 OCTETS),
SERVERID VARCHAR(256 OCTETS),
STARTTIME TIMESTAMP,
FK_JOBINSTANCEID BIGINT NOT NULL,
CONSTRAINT PK_JOBEXECUTION PRIMARY KEY (JOBEXECID))
CREATE INDEX FHIR_BATCH.JE_FKINSTANCEID_IX ON FHIR_BATCH.JOBEXECUTION (FK_JOBINSTANCEID)
ALTER TABLE FHIR_BATCH.JOBEXECUTION ADD CONSTRAINT JBXCTNFKJBNSTNCEID FOREIGN KEY (FK_JOBINSTANCEID)
REFERENCES FHIR_BATCH.JOBINSTANCE (JOBINSTANCEID)
|
void |
JavaBatchSchemaGenerator.addJobInstanceTable(PhysicalDataModel model) |
Adds the Job Instance table with the following values:
CREATE TABLE FHIR_BATCH.JOBINSTANCE(
JOBINSTANCEID BIGINT GENERATED BY DEFAULT AS IDENTITY,
AMCNAME VARCHAR(512 OCTETS),
BATCHSTATUS INT NOT NULL,
CREATETIME TIMESTAMP NOT NULL,
EXITSTATUS VARCHAR(2048 OCTETS),
INSTANCESTATE INT NOT NULL,
JOBNAME VARCHAR(256 OCTETS),
JOBXMLNAME VARCHAR(128 OCTETS),
JOBXML BLOB(2147483647) INLINE LENGTH 10240,
NUMEXECS INT NOT NULL, RESTARTON VARCHAR(128 OCTETS),
SUBMITTER VARCHAR(256 OCTETS),
UPDATETIME TIMESTAMP,
CONSTRAINT PK_JOBINSTANCEID PRIMARY KEY (JOBINSTANCEID)
)
|
void |
JavaBatchSchemaGenerator.addJobParameterTable(PhysicalDataModel model) |
Adds the job table with the following values:
CREATE TABLE FHIR_BATCH.JOBPARAMETER (
NAME VARCHAR(255),
VALUE VARCHAR(255),
FK_JOBEXECID BIGINT)
CREATE INDEX FHIR_BATCH.JP_FKJOBEXECID_IX ON FHIR_BATCH.JOBPARAMETER (FK_JOBEXECID)
ALTER TABLE FHIR_BATCH.JOBPARAMETER ADD CONSTRAINT JBPRMETERFKJBXECID FOREIGN KEY (FK_JOBEXECID)
REFERENCES FHIR_BATCH.JOBEXECUTION (JOBEXECID)
|
Table |
FhirSchemaGenerator.addLogicalResourceCompartments(PhysicalDataModel pdm) |
Adds the system level logical_resource_compartments table which identifies to
which compartments a give resource belongs.
|
Table |
FhirSchemaGenerator.addLogicalResourceProfiles(PhysicalDataModel pdm) |
A single-parameter table supporting _profile search parameter values
Add the LOGICAL_RESOURCE_PROFILES table to the given PhysicalDataModel .
|
void |
FhirSchemaGenerator.addLogicalResources(PhysicalDataModel pdm) |
Add the system-wide logical_resources table.
|
Table |
FhirSchemaGenerator.addLogicalResourceSecurity(PhysicalDataModel pdm) |
Add the dedicated common_token_values mapping table for security search parameters
|
Table |
FhirSchemaGenerator.addLogicalResourceTags(PhysicalDataModel pdm) |
A single-parameter table supporting _tag search parameter values.
|
protected void |
FhirSchemaGenerator.addParameterNames(PhysicalDataModel model) |
CREATE TABLE parameter_names (
parameter_name_id INT NOT NULL
CONSTRAINT pk_parameter_name PRIMARY KEY,
parameter_name VARCHAR(255 OCTETS) NOT NULL
);
CREATE UNIQUE INDEX unq_parameter_name_rtnm ON parameter_names(parameter_name) INCLUDE (parameter_name_id);
|
protected void |
FhirSchemaGenerator.addReferencesSequence(PhysicalDataModel pdm) |
Add the sequence used by the new local/external references data model
|
void |
JavaBatchSchemaGenerator.addRemotablePartitionTable(PhysicalDataModel model) |
Adds the Remotable Partition table with the following values:
CREATE TABLE FHIR_BATCH.REMOTABLEPARTITION (
PARTNUM INTEGER NOT NULL,
STEPNAME VARCHAR(255) NOT NULL,
INTERNALSTATE INTEGER,
LASTUPDATED TIMESTAMP,
LOGPATH VARCHAR(512),
RESTURL VARCHAR(512),
SERVERID VARCHAR(256),
FK_JOBEXECUTIONID BIGINT NOT NULL,
FK_STEPEXECUTIONID BIGINT,
PRIMARY KEY (PARTNUM, STEPNAME, FK_JOBEXECUTIONID))
ALTER TABLE FHIR_BATCH.REMOTABLEPARTITION ADD CONSTRAINT RMOTABLEPARTITION0 UNIQUE (FK_JOBEXECUTIONID, STEPNAME, PARTNUM)
ALTER TABLE FHIR_BATCH.REMOTABLEPARTITION ADD CONSTRAINT RMTBLPRTFKSTPXCTND FOREIGN KEY (FK_STEPEXECUTIONID)
REFERENCES FHIR_BATCH.STEPTHREADEXECUTION (STEPEXECID)
ALTER TABLE FHIR_BATCH.REMOTABLEPARTITION ADD CONSTRAINT RMTBLPRTTFKJBXCTND FOREIGN KEY (FK_JOBEXECUTIONID)
REFERENCES FHIR_BATCH.JOBEXECUTION (JOBEXECID)
|
void |
FhirSchemaGenerator.addResourceChangeLog(PhysicalDataModel pdm) |
Add the resource_change_log table.
|
Table |
FhirSchemaGenerator.addResourceDateValues(PhysicalDataModel model) |
Add the table for data search parameters at the (system-wide) resource level
|
Table |
FhirSchemaGenerator.addResourceStrValues(PhysicalDataModel pdm) |
Add system-wide RESOURCE_STR_VALUES table to support _profile
properties (which are of type REFERENCE).
|
protected void |
FhirSchemaGenerator.addResourceTables(PhysicalDataModel model,
IDatabaseObject... dependency) |
Add the collection of tables for each of the listed
FHIR resource types
|
Table |
FhirSchemaGenerator.addResourceTokenRefs(PhysicalDataModel pdm) |
Add the system-wide RESOURCE_TOKEN_REFS table which is used for
_tag and _security search properties in R4 (new table
for issue #1366 V0006 schema change).
|
protected void |
FhirSchemaGenerator.addResourceTypes(PhysicalDataModel model) |
CREATE TABLE resource_types (
resource_type_id INT NOT NULL
CONSTRAINT pk_resource_type PRIMARY KEY,
resource_type VARCHAR(64) NOT NULL
);
-- make sure resource_type values are unique
CREATE UNIQUE INDEX unq_resource_types_rt ON resource_types(resource_type);
|
void |
JavaBatchSchemaGenerator.addStepThreadExecutionTable(PhysicalDataModel model) |
Adds the Step Thread Execution table with the following values:
CREATE TABLE FHIR_BATCH.STEPTHREADEXECUTION(
STEPEXECID BIGINT GENERATED BY DEFAULT AS IDENTITY,
THREADTYPE VARCHAR(31 OCTETS),
BATCHSTATUS INT NOT NULL,
M_COMMIT BIGINT NOT NULL,
ENDTIME TIMESTAMP,
EXITSTATUS VARCHAR(512 OCTETS),
M_FILTER BIGINT NOT NULL,
INTERNAL_STATUS INT NOT NULL,
PARTNUM INT NOT NULL,
USERDATA BLOB(2147483647)
INLINE LENGTH 10240 NOT NULL,
M_PROCESSSKIP BIGINT NOT NULL,
M_READ BIGINT NOT NULL,
M_READSKIP BIGINT NOT NULL,
M_ROLLBACK BIGINT NOT NULL,
STARTTIME TIMESTAMP,
STEPNAME VARCHAR(128 OCTETS) NOT NULL,
M_WRITE BIGINT NOT NULL,
M_WRITESKIP BIGINT NOT NULL,
FK_JOBEXECID BIGINT NOT NULL,
FK_TOPLVL_STEPEXECID BIGINT NOT NULL,
ISPARTITIONEDSTEP SMALLINT,
CONSTRAINT PK_STEPTHREADEXECUTION PRIMARY KEY (STEPEXECID))
CREATE INDEX FHIR_BATCH.STE_FKJOBEXECID_IX ON FHIR_BATCH.STEPTHREADEXECUTION (FK_JOBEXECID)
CREATE INDEX FHIR_BATCH.STE_FKTLSTEPEID_IX ON FHIR_BATCH.STEPTHREADEXECUTION (FK_TOPLVL_STEPEXECID)
ALTER TABLE FHIR_BATCH.STEPTHREADEXECUTION ADD CONSTRAINT STPTHRADEXECUTION0 UNIQUE (FK_JOBEXECID, STEPNAME, PARTNUM)
ALTER TABLE FHIR_BATCH.STEPTHREADEXECUTION ADD CONSTRAINT STPTHFKTPLVLSTPXCD FOREIGN KEY (FK_TOPLVL_STEPEXECID)
REFERENCES FHIR_BATCH.STEPTHREADEXECUTION (STEPEXECID)
ALTER TABLE FHIR_BATCH.STEPTHREADEXECUTION ADD CONSTRAINT STPTHRDXCTNFKJBXCD FOREIGN KEY (FK_JOBEXECID)
REFERENCES FHIR_BATCH.JOBEXECUTION (JOBEXECID)
|
void |
JavaBatchSchemaGenerator.addStepThreadInstanceTable(PhysicalDataModel model) |
Adds the Step Thread Instance table with the following values:
CREATE TABLE FHIR_BATCH.STEPTHREADINSTANCE(
PARTNUM BIGINT NOT NULL,
STEPNAME VARCHAR(128 OCTETS) NOT NULL,
THREADTYPE VARCHAR(31 OCTETS),
CHECKPOINTDATA BLOB(2147483647) INLINE LENGTH 10240,
FK_JOBINSTANCEID BIGINT NOT NULL,
FK_LATEST_STEPEXECID BIGINT NOT NULL,
PARTITIONED SMALLINT NOT NULL,
PARTITIONPLANSIZE INT,
STARTCOUNT INT,
CONSTRAINT PK_STEPTHREADINSTANCE PRIMARY KEY (PARTNUM, STEPNAME, FK_JOBINSTANCEID))
CREATE INDEX FHIR_BATCH.STI_FKINSTANCEID_IX ON FHIR_BATCH.STEPTHREADINSTANCE (FK_JOBINSTANCEID)
CREATE INDEX FHIR_BATCH.STI_FKLATEST_SEI_IX ON FHIR_BATCH.STEPTHREADINSTANCE (FK_LATEST_STEPEXECID)
ALTER TABLE FHIR_BATCH.STEPTHREADINSTANCE ADD CONSTRAINT STPTHRFKLTSTSTPXCD FOREIGN KEY (FK_LATEST_STEPEXECID)
REFERENCES FHIR_BATCH.STEPTHREADEXECUTION (STEPEXECID)
ALTER TABLE FHIR_BATCH.STEPTHREADINSTANCE ADD CONSTRAINT STPTHRDNFKJBNSTNCD FOREIGN KEY (FK_JOBINSTANCEID)
REFERENCES FHIR_BATCH.JOBINSTANCE (JOBINSTANCEID)
|
protected void |
FhirSchemaGenerator.addTenantKeysTable(PhysicalDataModel model) |
Each tenant can have multiple access keys which are used to authenticate and authorize
clients for access to the data for a given tenant.
|
protected void |
FhirSchemaGenerator.addTenantSequence(PhysicalDataModel pdm) |
CREATE SEQUENCE fhir_sequence
AS BIGINT
START WITH 1
CACHE 1000
NO CYCLE;
|
protected void |
FhirSchemaGenerator.addTenantTable(PhysicalDataModel model) |
Create a table to manage the list of tenants.
|
void |
FhirSchemaGenerator.buildAdminSchema(PhysicalDataModel model) |
Build the admin part of the schema.
|
void |
FhirSchemaGenerator.buildDatabaseSpecificArtifactsCitus(PhysicalDataModel model) |
Add stored procedures/functions for Citus (largely based on PostgreSQL, but some functions are distributed
based on a parameter to make them more efficient.
|
void |
FhirSchemaGenerator.buildDatabaseSpecificArtifactsPostgres(PhysicalDataModel model) |
|
void |
JavaBatchSchemaGenerator.buildJavaBatchSchema(PhysicalDataModel model) |
Create the tables needed by the Liberty JBatch databaseStore
|
void |
OAuthSchemaGenerator.buildOAuthSchema(PhysicalDataModel model) |
Create the tables needed by the Liberty OAuthProvider databaseStore
|
void |
FhirSchemaGenerator.buildSchema(PhysicalDataModel model) |
Create the schema using the given target
|