Migration sql changes (#199)
* safe migration script changes * lamassu migration script fixes
This commit is contained in:
parent
65ce8aee3d
commit
12c834469c
53 changed files with 500 additions and 346 deletions
|
|
@ -4,14 +4,14 @@ var db = require('./db')
|
|||
|
||||
exports.up = function (next) {
|
||||
db.multi(['CREATE TABLE IF NOT EXISTS cached_responses ( ' +
|
||||
'id serial PRIMARY KEY, ' +
|
||||
'device_fingerprint text NOT NULL, ' +
|
||||
'session_id uuid NOT NULL, ' +
|
||||
'path text NOT NULL, ' +
|
||||
'method text NOT NULL, ' +
|
||||
'body json NOT NULL, ' +
|
||||
'created timestamptz NOT NULL DEFAULT now(), ' +
|
||||
'UNIQUE (device_fingerprint, session_id, path, method) ' +
|
||||
'id serial PRIMARY KEY, ' +
|
||||
'device_fingerprint text NOT NULL, ' +
|
||||
'session_id uuid NOT NULL, ' +
|
||||
'path text NOT NULL, ' +
|
||||
'method text NOT NULL, ' +
|
||||
'body json NOT NULL, ' +
|
||||
'created timestamptz NOT NULL DEFAULT now(), ' +
|
||||
'UNIQUE (device_fingerprint, session_id, path, method) ' +
|
||||
')'], next)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue