1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-27 09:12:41 +01:00
phorge-phorge/resources/sql/autopatches/20160418.repouri.1.sql
epriestley 9352ed8abb Add missing RepositoryURI table + run storage adjustments in tests
Summary:
Fixes T10830. Ref T10366. I wasn't writing to this table yet so I didn't build it, but the fact that `bin/storage adjust` would complain slipped my mind.

  - Add the table.
  - Make the tests run `adjust`. This is a little slow (a few extra seconds) but we could eventually move some steps like this to run server-side only.

Test Plan: Ran `bin/storage upgrade -f`, got a clean `adjust`.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T10366, T10830

Differential Revision: https://secure.phabricator.com/D15744
2016-04-18 07:54:02 -07:00

14 lines
686 B
SQL

CREATE TABLE {$NAMESPACE}_repository.repository_uri (
id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
phid VARBINARY(64) NOT NULL,
repositoryPHID VARBINARY(64) NOT NULL,
uri VARCHAR(255) NOT NULL COLLATE {$COLLATE_TEXT},
builtinProtocol VARCHAR(32) COLLATE {$COLLATE_TEXT},
builtinIdentifier VARCHAR(32) COLLATE {$COLLATE_TEXT},
ioType VARCHAR(32) NOT NULL COLLATE {$COLLATE_TEXT},
displayType VARCHAR(32) NOT NULL COLLATE {$COLLATE_TEXT},
isDisabled BOOL NOT NULL,
dateCreated INT UNSIGNED NOT NULL,
dateModified INT UNSIGNED NOT NULL,
UNIQUE KEY `key_builtin` (repositoryPHID, builtinProtocol, builtinIdentifier)
) ENGINE=InnoDB, COLLATE {$COLLATE_TEXT};