@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Generate reasonable expected schemata for Chatlog, Conduit, Config, Countdown, Daemons

Summary: Ref T1191. Fills in some more of the databases. Nothing very notable here. I didn't encounter any issues or overlong keys.

Test Plan: Used web UI to click around and verify expected schemata match up against actual schemata well.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T1191

Differential Revision: https://secure.phabricator.com/D10516

+165
+10
src/__phutil_library_map__.php
··· 1310 1310 'PhabricatorChatLogEvent' => 'applications/chatlog/storage/PhabricatorChatLogEvent.php', 1311 1311 'PhabricatorChatLogEventType' => 'applications/chatlog/constants/PhabricatorChatLogEventType.php', 1312 1312 'PhabricatorChatLogQuery' => 'applications/chatlog/query/PhabricatorChatLogQuery.php', 1313 + 'PhabricatorChatLogSchemaSpec' => 'applications/chatlog/storage/PhabricatorChatLogSchemaSpec.php', 1313 1314 'PhabricatorCommitBranchesField' => 'applications/repository/customfield/PhabricatorCommitBranchesField.php', 1314 1315 'PhabricatorCommitCustomField' => 'applications/repository/customfield/PhabricatorCommitCustomField.php', 1315 1316 'PhabricatorCommitSearchEngine' => 'applications/audit/query/PhabricatorCommitSearchEngine.php', ··· 1328 1329 'PhabricatorConduitLogQuery' => 'applications/conduit/query/PhabricatorConduitLogQuery.php', 1329 1330 'PhabricatorConduitMethodCallLog' => 'applications/conduit/storage/PhabricatorConduitMethodCallLog.php', 1330 1331 'PhabricatorConduitMethodQuery' => 'applications/conduit/query/PhabricatorConduitMethodQuery.php', 1332 + 'PhabricatorConduitSchemaSpec' => 'applications/conduit/storage/PhabricatorConduitSchemaSpec.php', 1331 1333 'PhabricatorConduitSearchEngine' => 'applications/conduit/query/PhabricatorConduitSearchEngine.php', 1332 1334 'PhabricatorConduitTokenController' => 'applications/conduit/controller/PhabricatorConduitTokenController.php', 1333 1335 'PhabricatorConfigAllController' => 'applications/config/controller/PhabricatorConfigAllController.php', ··· 1367 1369 'PhabricatorConfigSchemaQuery' => 'applications/config/schema/PhabricatorConfigSchemaQuery.php', 1368 1370 'PhabricatorConfigSchemaSpec' => 'applications/config/schema/PhabricatorConfigSchemaSpec.php', 1369 1371 'PhabricatorConfigServerSchema' => 'applications/config/schema/PhabricatorConfigServerSchema.php', 1372 + 'PhabricatorConfigSettingsSchemaSpec' => 'applications/config/storage/PhabricatorConfigSettingsSchemaSpec.php', 1370 1373 'PhabricatorConfigSource' => 'infrastructure/env/PhabricatorConfigSource.php', 1371 1374 'PhabricatorConfigStackSource' => 'infrastructure/env/PhabricatorConfigStackSource.php', 1372 1375 'PhabricatorConfigStorageSchema' => 'applications/config/schema/PhabricatorConfigStorageSchema.php', ··· 1393 1396 'PhabricatorCountdownListController' => 'applications/countdown/controller/PhabricatorCountdownListController.php', 1394 1397 'PhabricatorCountdownQuery' => 'applications/countdown/query/PhabricatorCountdownQuery.php', 1395 1398 'PhabricatorCountdownRemarkupRule' => 'applications/countdown/remarkup/PhabricatorCountdownRemarkupRule.php', 1399 + 'PhabricatorCountdownSchemaSpec' => 'applications/countdown/storage/PhabricatorCountdownSchemaSpec.php', 1396 1400 'PhabricatorCountdownSearchEngine' => 'applications/countdown/query/PhabricatorCountdownSearchEngine.php', 1397 1401 'PhabricatorCountdownView' => 'applications/countdown/view/PhabricatorCountdownView.php', 1398 1402 'PhabricatorCountdownViewController' => 'applications/countdown/controller/PhabricatorCountdownViewController.php', ··· 1438 1442 'PhabricatorDaemonManagementStopWorkflow' => 'applications/daemon/management/PhabricatorDaemonManagementStopWorkflow.php', 1439 1443 'PhabricatorDaemonManagementWorkflow' => 'applications/daemon/management/PhabricatorDaemonManagementWorkflow.php', 1440 1444 'PhabricatorDaemonReference' => 'infrastructure/daemon/control/PhabricatorDaemonReference.php', 1445 + 'PhabricatorDaemonSchemaSpec' => 'applications/daemon/storage/PhabricatorDaemonSchemaSpec.php', 1441 1446 'PhabricatorDaemonTaskGarbageCollector' => 'applications/daemon/garbagecollector/PhabricatorDaemonTaskGarbageCollector.php', 1442 1447 'PhabricatorDaemonsApplication' => 'applications/daemon/application/PhabricatorDaemonsApplication.php', 1443 1448 'PhabricatorDashboard' => 'applications/dashboard/storage/PhabricatorDashboard.php', ··· 4203 4208 ), 4204 4209 'PhabricatorChatLogEventType' => 'PhabricatorChatLogConstants', 4205 4210 'PhabricatorChatLogQuery' => 'PhabricatorCursorPagedPolicyAwareQuery', 4211 + 'PhabricatorChatLogSchemaSpec' => 'PhabricatorConfigSchemaSpec', 4206 4212 'PhabricatorCommitBranchesField' => 'PhabricatorCommitCustomField', 4207 4213 'PhabricatorCommitCustomField' => 'PhabricatorCustomField', 4208 4214 'PhabricatorCommitSearchEngine' => 'PhabricatorApplicationSearchEngine', ··· 4224 4230 'PhabricatorPolicyInterface', 4225 4231 ), 4226 4232 'PhabricatorConduitMethodQuery' => 'PhabricatorCursorPagedPolicyAwareQuery', 4233 + 'PhabricatorConduitSchemaSpec' => 'PhabricatorConfigSchemaSpec', 4227 4234 'PhabricatorConduitSearchEngine' => 'PhabricatorApplicationSearchEngine', 4228 4235 'PhabricatorConduitTokenController' => 'PhabricatorConduitController', 4229 4236 'PhabricatorConfigAllController' => 'PhabricatorConfigController', ··· 4267 4274 'PhabricatorConfigSchemaQuery' => 'Phobject', 4268 4275 'PhabricatorConfigSchemaSpec' => 'Phobject', 4269 4276 'PhabricatorConfigServerSchema' => 'PhabricatorConfigStorageSchema', 4277 + 'PhabricatorConfigSettingsSchemaSpec' => 'PhabricatorConfigSchemaSpec', 4270 4278 'PhabricatorConfigStackSource' => 'PhabricatorConfigSource', 4271 4279 'PhabricatorConfigStorageSchema' => 'Phobject', 4272 4280 'PhabricatorConfigTableSchema' => 'PhabricatorConfigStorageSchema', ··· 4294 4302 'PhabricatorCountdownListController' => 'PhabricatorCountdownController', 4295 4303 'PhabricatorCountdownQuery' => 'PhabricatorCursorPagedPolicyAwareQuery', 4296 4304 'PhabricatorCountdownRemarkupRule' => 'PhabricatorObjectRemarkupRule', 4305 + 'PhabricatorCountdownSchemaSpec' => 'PhabricatorConfigSchemaSpec', 4297 4306 'PhabricatorCountdownSearchEngine' => 'PhabricatorApplicationSearchEngine', 4298 4307 'PhabricatorCountdownView' => 'AphrontTagView', 4299 4308 'PhabricatorCountdownViewController' => 'PhabricatorCountdownController', ··· 4338 4347 'PhabricatorDaemonManagementStatusWorkflow' => 'PhabricatorDaemonManagementWorkflow', 4339 4348 'PhabricatorDaemonManagementStopWorkflow' => 'PhabricatorDaemonManagementWorkflow', 4340 4349 'PhabricatorDaemonManagementWorkflow' => 'PhabricatorManagementWorkflow', 4350 + 'PhabricatorDaemonSchemaSpec' => 'PhabricatorConfigSchemaSpec', 4341 4351 'PhabricatorDaemonTaskGarbageCollector' => 'PhabricatorGarbageCollector', 4342 4352 'PhabricatorDaemonsApplication' => 'PhabricatorApplication', 4343 4353 'PhabricatorDashboard' => array(
+15
src/applications/chatlog/storage/PhabricatorChatLogChannel.php
··· 10 10 protected $viewPolicy; 11 11 protected $editPolicy; 12 12 13 + public function getConfiguration() { 14 + return array( 15 + self::CONFIG_COLUMN_SCHEMA => array( 16 + 'serviceName' => 'text64', 17 + 'serviceType' => 'text32', 18 + 'channelName' => 'text64', 19 + ), 20 + self::CONFIG_KEY_SCHEMA => array( 21 + 'key_channel' => array( 22 + 'columns' => array('channelName', 'serviceType', 'serviceName'), 23 + ), 24 + ), 25 + ) + parent::getConfiguration(); 26 + } 27 + 13 28 public function getCapabilities() { 14 29 return array( 15 30 PhabricatorPolicyCapability::CAN_VIEW,
+5
src/applications/chatlog/storage/PhabricatorChatLogEvent.php
··· 16 16 public function getConfiguration() { 17 17 return array( 18 18 self::CONFIG_TIMESTAMPS => false, 19 + self::CONFIG_COLUMN_SCHEMA => array( 20 + 'author' => 'text64', 21 + 'type' => 'text4', 22 + 'message' => 'text', 23 + ), 19 24 ) + parent::getConfiguration(); 20 25 } 21 26
+9
src/applications/chatlog/storage/PhabricatorChatLogSchemaSpec.php
··· 1 + <?php 2 + 3 + final class PhabricatorChatLogSchemaSpec extends PhabricatorConfigSchemaSpec { 4 + 5 + public function buildSchemata() { 6 + $this->buildLiskSchemata('PhabricatorChatLogDAO'); 7 + } 8 + 9 + }
+16
src/applications/conduit/storage/PhabricatorConduitCertificateToken.php
··· 5 5 protected $userPHID; 6 6 protected $token; 7 7 8 + public function getConfiguration() { 9 + return array( 10 + self::CONFIG_COLUMN_SCHEMA => array( 11 + 'token' => 'text64?', 12 + ), 13 + self::CONFIG_KEY_SCHEMA => array( 14 + 'userPHID' => array( 15 + 'columns' => array('userPHID'), 16 + ), 17 + 'token' => array( 18 + 'columns' => array('token'), 19 + ), 20 + ), 21 + ) + parent::getConfiguration(); 22 + } 23 + 8 24 }
+11
src/applications/conduit/storage/PhabricatorConduitConnectionLog.php
··· 7 7 protected $clientDescription; 8 8 protected $username; 9 9 10 + public function getConfiguration() { 11 + return array( 12 + self::CONFIG_COLUMN_SCHEMA => array( 13 + 'client' => 'text255?', 14 + 'clientVersion' => 'text255?', 15 + 'clientDescription' => 'text255?', 16 + 'username' => 'text255?', 17 + ), 18 + ) + parent::getConfiguration(); 19 + } 20 + 10 21 }
+13
src/applications/conduit/storage/PhabricatorConduitMethodCallLog.php
··· 10 10 protected $error; 11 11 protected $duration; 12 12 13 + public function getConfiguration() { 14 + return array( 15 + self::CONFIG_COLUMN_SCHEMA => array( 16 + 'id' => 'id64', 17 + 'connectionID' => 'id64?', 18 + 'method' => 'text255', 19 + 'error' => 'text255', 20 + 'duration' => 'uint64', 21 + 'callerPHID' => 'phid?', 22 + ), 23 + ) + parent::getConfiguration(); 24 + } 25 + 13 26 14 27 /* -( PhabricatorPolicyInterface )----------------------------------------- */ 15 28
+9
src/applications/conduit/storage/PhabricatorConduitSchemaSpec.php
··· 1 + <?php 2 + 3 + final class PhabricatorConduitSchemaSpec extends PhabricatorConfigSchemaSpec { 4 + 5 + public function buildSchemata() { 6 + $this->buildLiskSchemata('PhabricatorConduitDAO'); 7 + } 8 + 9 + }
+21
src/applications/config/schema/PhabricatorConfigSchemaSpec.php
··· 158 158 $column_type = 'int(10) unsigned'; 159 159 break; 160 160 case 'id64': 161 + case 'uint64': 161 162 $column_type = 'bigint(20) unsigned'; 162 163 break; 163 164 case 'phid': 164 165 case 'policy'; 165 166 $column_type = 'varchar(64)'; 167 + $charset = 'binary'; 168 + $collation = 'binary'; 169 + break; 170 + case 'bytes40': 171 + $column_type = 'char(40)'; 166 172 $charset = 'binary'; 167 173 $collation = 'binary'; 168 174 break; ··· 175 181 $column_type = 'longblob'; 176 182 $charset = 'binary'; 177 183 $collation = 'binary'; 184 + break; 185 + case 'text255': 186 + $column_type = 'varchar(255)'; 187 + $charset = $this->getUTF8Charset(); 188 + $collation = $this->getUTF8Collation(); 178 189 break; 179 190 case 'text128': 180 191 $column_type = 'varchar(128)'; ··· 198 209 break; 199 210 case 'text12': 200 211 $column_type = 'varchar(12)'; 212 + $charset = $this->getUTF8Charset(); 213 + $collation = $this->getUTF8Collation(); 214 + break; 215 + case 'text8': 216 + $column_type = 'varchar(8)'; 217 + $charset = $this->getUTF8Charset(); 218 + $collation = $this->getUTF8Collation(); 219 + break; 220 + case 'text4': 221 + $column_type = 'varchar(4)'; 201 222 $charset = $this->getUTF8Charset(); 202 223 $collation = $this->getUTF8Collation(); 203 224 break;
+10
src/applications/config/storage/PhabricatorConfigEntry.php
··· 14 14 self::CONFIG_SERIALIZATION => array( 15 15 'value' => self::SERIALIZATION_JSON, 16 16 ), 17 + self::CONFIG_COLUMN_SCHEMA => array( 18 + 'namespace' => 'text64', 19 + 'configKey' => 'text64', 20 + 'isDeleted' => 'bool', 21 + ), 22 + self::CONFIG_KEY_SCHEMA => array( 23 + 'key_name' => array( 24 + 'columns' => array('namespace', 'configKey'), 25 + ), 26 + ), 17 27 ) + parent::getConfiguration(); 18 28 } 19 29
+11
src/applications/config/storage/PhabricatorConfigSettingsSchemaSpec.php
··· 1 + <?php 2 + 3 + final class PhabricatorConfigSettingsSchemaSpec 4 + extends PhabricatorConfigSchemaSpec { 5 + 6 + public function buildSchemata() { 7 + $this->buildLiskSchemata('PhabricatorConfigEntryDAO'); 8 + $this->buildTransactionSchema(new PhabricatorConfigTransaction()); 9 + } 10 + 11 + }
+3
src/applications/countdown/storage/PhabricatorCountdown.php
··· 27 27 public function getConfiguration() { 28 28 return array( 29 29 self::CONFIG_AUX_PHID => true, 30 + self::CONFIG_COLUMN_SCHEMA => array( 31 + 'title' => 'text255', 32 + ), 30 33 ) + parent::getConfiguration(); 31 34 } 32 35
+10
src/applications/countdown/storage/PhabricatorCountdownSchemaSpec.php
··· 1 + <?php 2 + 3 + final class PhabricatorCountdownSchemaSpec 4 + extends PhabricatorConfigSchemaSpec { 5 + 6 + public function buildSchemata() { 7 + $this->buildLiskSchemata('PhabricatorCountdownDAO'); 8 + } 9 + 10 + }
+7
src/applications/daemon/storage/PhabricatorDaemonLog.php
··· 24 24 'argv' => self::SERIALIZATION_JSON, 25 25 'explicitArgv' => self::SERIALIZATION_JSON, 26 26 ), 27 + self::CONFIG_COLUMN_SCHEMA => array( 28 + 'daemon' => 'text255', 29 + 'host' => 'text255', 30 + 'pid' => 'uint32', 31 + 'envHash' => 'bytes40', 32 + 'status' => 'text8', 33 + ), 27 34 ) + parent::getConfiguration(); 28 35 } 29 36
+4
src/applications/daemon/storage/PhabricatorDaemonLogEvent.php
··· 10 10 public function getConfiguration() { 11 11 return array( 12 12 self::CONFIG_TIMESTAMPS => false, 13 + self::CONFIG_COLUMN_SCHEMA => array( 14 + 'logType' => 'text4', 15 + 'message' => 'text', 16 + ), 13 17 ) + parent::getConfiguration(); 14 18 } 15 19
+10
src/applications/daemon/storage/PhabricatorDaemonSchemaSpec.php
··· 1 + <?php 2 + 3 + final class PhabricatorDaemonSchemaSpec 4 + extends PhabricatorConfigSchemaSpec { 5 + 6 + public function buildSchemata() { 7 + $this->buildLiskSchemata('PhabricatorDaemonDAO'); 8 + } 9 + 10 + }
+1
src/infrastructure/storage/lisk/LiskDAO.php
··· 1742 1742 'phid' => 'phid', 1743 1743 'viewPolicy' => 'policy', 1744 1744 'editPolicy' => 'policy', 1745 + 'epoch' => 'epoch', 1745 1746 'dateCreated' => 'epoch', 1746 1747 'dateModified' => 'epoch', 1747 1748 );