Rev 201 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed
-- Create Schema for Brutex
CREATE SCHEMA IF NOT EXISTS brutex;
CREATE TABLE IF NOT EXISTS brutex.tbl_events
(
btx_event_type VARCHAR(128) NOT NULL,
btx_id VARCHAR(128) NOT NULL,
btx_obj_type VARCHAR(32) NOT NULL,
btx_obj_id VARCHAR(32) NOT NULL,
btx_timestamp BIGINT NOT NULL,
btx_event CLOB
);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_key ON brutex.tbl_events (btx_obj_id, btx_obj_type, btx_event_type);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_ts ON brutex.tbl_events (btx_timestamp ASC);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_id ON brutex.tbl_events (btx_id);
CREATE TABLE IF NOT EXISTS brutex.tbl_events_snap
(
btx_event_type VARCHAR(128) NOT NULL,
btx_id VARCHAR(128) NOT NULL,
btx_obj_type VARCHAR(32) NOT NULL,
btx_obj_id VARCHAR(32) NOT NULL,
btx_timestamp BIGINT NOT NULL,
btx_run BIGINT NOT NULL,
btx_event CLOB
);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_ts ON brutex.tbl_events_snap (btx_timestamp ASC);
CREATE TABLE IF NOT EXISTS brutex.tbl_events_errors
(
btx_event_type VARCHAR(128) NOT NULL,
btx_id VARCHAR(128) NOT NULL,
btx_obj_type VARCHAR(32) NOT NULL,
btx_obj_id VARCHAR(32) NOT NULL,
btx_timestamp BIGINT NOT NULL,
btx_retry BOOL,
btx_response CLOB,
btx_event CLOB
);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_ts ON brutex.tbl_events_errors (btx_timestamp ASC);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_retry ON brutex.tbl_events_errors (btx_retry);
CREATE TABLE IF NOT EXISTS brutex.tbl_events_all
(
btx_event_type VARCHAR(128) NOT NULL,
btx_id VARCHAR(128) NOT NULL,
btx_obj_type VARCHAR(32) NOT NULL,
btx_obj_id VARCHAR(32) NOT NULL,
btx_timestamp BIGINT NOT NULL,
btx_supersed_id VARCHAR(128),
btx_event CLOB
);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_ssed ON brutex.tbl_events_all (btx_supersed_id);
CREATE INDEX IF NOT EXISTS brutex.btx_idx_ts ON brutex.tbl_events_all (btx_timestamp ASC);
Generated by GNU Enscript 1.6.5.90.