chore: use monorepo organization
This commit is contained in:
parent
deaf7d6ecc
commit
a687827f7e
1099 changed files with 8184 additions and 11535 deletions
20
packages/server/migrations/010-cached-requests.js
Normal file
20
packages/server/migrations/010-cached-requests.js
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
'use strict'
|
||||
|
||||
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) ' +
|
||||
')'], next)
|
||||
}
|
||||
|
||||
exports.down = function (next) {
|
||||
next()
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue