-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
109 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
-- +goose Up | ||
|
||
CREATE TABLE sessions ( | ||
beginstring CHAR(8) NOT NULL, | ||
sendercompid VARCHAR(64) NOT NULL, | ||
sendersubid VARCHAR(64) NOT NULL, | ||
senderlocid VARCHAR(64) NOT NULL, | ||
targetcompid VARCHAR(64) NOT NULL, | ||
targetsubid VARCHAR(64) NOT NULL, | ||
targetlocid VARCHAR(64) NOT NULL, | ||
session_qualifier VARCHAR(64) NOT NULL, | ||
creation_time TIMESTAMP WITH TIME ZONE NOT NULL, | ||
incoming_seqnum INTEGER NOT NULL, | ||
outgoing_seqnum INTEGER NOT NULL, | ||
PRIMARY KEY (beginstring, sendercompid, sendersubid, senderlocid, | ||
targetcompid, targetsubid, targetlocid, session_qualifier) | ||
); | ||
|
||
-- +goose Down | ||
DROP TABLE sessions CASCADE; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
-- +goose Up | ||
|
||
CREATE TABLE messages ( | ||
beginstring CHAR(8) NOT NULL, | ||
sendercompid VARCHAR(64) NOT NULL, | ||
sendersubid VARCHAR(64) NOT NULL, | ||
senderlocid VARCHAR(64) NOT NULL, | ||
targetcompid VARCHAR(64) NOT NULL, | ||
targetsubid VARCHAR(64) NOT NULL, | ||
targetlocid VARCHAR(64) NOT NULL, | ||
session_qualifier VARCHAR(64) NOT NULL, | ||
msgseqnum INTEGER NOT NULL, | ||
message TEXT NOT NULL, | ||
PRIMARY KEY (beginstring, sendercompid, sendersubid, senderlocid, | ||
targetcompid, targetsubid, targetlocid, session_qualifier, | ||
msgseqnum) | ||
); | ||
|
||
-- +goose Down | ||
DROP TABLE messages CASCADE; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
-- +goose Up | ||
CREATE SEQUENCE messages_log_sequence; | ||
|
||
CREATE TABLE messages_log ( | ||
id INTEGER DEFAULT NEXTVAL('messages_log_sequence'), | ||
time TIMESTAMP WITH TIME ZONE NOT NULL, | ||
beginstring CHAR(8) NOT NULL, | ||
sendercompid VARCHAR(64) NOT NULL, | ||
sendersubid VARCHAR(64) NOT NULL, | ||
senderlocid VARCHAR(64) NOT NULL, | ||
targetcompid VARCHAR(64) NOT NULL, | ||
targetsubid VARCHAR(64) NOT NULL, | ||
targetlocid VARCHAR(64) NOT NULL, | ||
session_qualifier VARCHAR(64), | ||
text TEXT NOT NULL, | ||
PRIMARY KEY (id) | ||
); | ||
|
||
-- +goose Down | ||
DROP TABLE messages_log CASCADE; | ||
DROP SEQUENCE messages_log_sequence; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
-- +goose Up | ||
|
||
CREATE SEQUENCE event_log_sequence; | ||
|
||
CREATE TABLE event_log ( | ||
id INTEGER DEFAULT NEXTVAL('event_log_sequence'), | ||
time TIMESTAMP WITH TIME ZONE NOT NULL, | ||
beginstring CHAR(8) NOT NULL, | ||
sendercompid VARCHAR(64) NOT NULL, | ||
sendersubid VARCHAR(64) NOT NULL, | ||
senderlocid VARCHAR(64) NOT NULL, | ||
targetcompid VARCHAR(64) NOT NULL, | ||
targetsubid VARCHAR(64) NOT NULL, | ||
targetlocid VARCHAR(64) NOT NULL, | ||
session_qualifier VARCHAR(64), | ||
text TEXT NOT NULL, | ||
PRIMARY KEY (id) | ||
); | ||
|
||
-- +goose Down | ||
DROP TABLE event_log CASCADE; | ||
DROP SEQUENCE event_log_sequence; |