X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=static%2Fdbstructure.config.php;h=df5115dcb41c09d114e7f3775b921ede1bacd3a7;hb=4a885a13a69c1a579d040f26891d66791d4cead0;hp=c48da6a09a12f39985e40d60bf29a09b3c3e5403;hpb=7528b7946945c23f93ccec84fdcb65a75f06ad33;p=friendica.git diff --git a/static/dbstructure.config.php b/static/dbstructure.config.php index c48da6a09a..df5115dcb4 100644 --- a/static/dbstructure.config.php +++ b/static/dbstructure.config.php @@ -55,7 +55,7 @@ use Friendica\Database\DBA; if (!defined('DB_UPDATE_VERSION')) { - define('DB_UPDATE_VERSION', 1472); + define('DB_UPDATE_VERSION', 1478); } return [ @@ -358,6 +358,7 @@ return [ "cookie_hash" => ["type" => "varchar(80)", "not null" => "1", "primary" => "1", "comment" => "Trusted cookie hash"], "uid" => ["type" => "mediumint unsigned", "not null" => "1", "foreign" => ["user" => "uid"], "comment" => "User ID"], "user_agent" => ["type" => "text", "comment" => "User agent string"], + "trusted" => ["type" => "boolean", "not null" => "1", "default" => "1", "comment" => "Whenever this browser should be trusted or not"], "created" => ["type" => "datetime", "not null" => "1", "comment" => "Datetime the trusted browser was recorded"], "last_used" => ["type" => "datetime", "comment" => "Datetime the trusted browser was last used"], ], @@ -399,6 +400,7 @@ return [ "featured-tags" => ["type" => "varchar(255)", "comment" => "Address for the collection of featured tags"], "manually-approve" => ["type" => "boolean", "comment" => ""], "discoverable" => ["type" => "boolean", "comment" => "Mastodon extension: true if profile is published in their directory"], + "suspended" => ["type" => "boolean", "comment" => "Mastodon extension: true if profile is suspended"], "nick" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""], "name" => ["type" => "varchar(255)", "comment" => ""], "about" => ["type" => "text", "comment" => ""], @@ -564,24 +566,6 @@ return [ "uid" => ["uid"], ] ], - "conversation" => [ - "comment" => "Raw data and structure information for messages", - "fields" => [ - "item-uri" => ["type" => "varbinary(255)", "not null" => "1", "primary" => "1", "comment" => "Original URI of the item - unrelated to the table with the same name"], - "reply-to-uri" => ["type" => "varbinary(255)", "not null" => "1", "default" => "", "comment" => "URI to which this item is a reply"], - "conversation-uri" => ["type" => "varbinary(255)", "not null" => "1", "default" => "", "comment" => "GNU Social conversation URI"], - "conversation-href" => ["type" => "varbinary(255)", "not null" => "1", "default" => "", "comment" => "GNU Social conversation link"], - "protocol" => ["type" => "tinyint unsigned", "not null" => "1", "default" => "255", "comment" => "The protocol of the item"], - "direction" => ["type" => "tinyint unsigned", "not null" => "1", "default" => "0", "comment" => "How the message arrived here: 1=push, 2=pull"], - "source" => ["type" => "mediumtext", "comment" => "Original source"], - "received" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Receiving date"], - ], - "indexes" => [ - "PRIMARY" => ["item-uri"], - "conversation-uri" => ["conversation-uri"], - "received" => ["received"], - ] - ], "workerqueue" => [ "comment" => "Background tasks queue entries", "fields" => [ @@ -708,6 +692,20 @@ return [ "uri-id" => ["UNIQUE", "uri-id"], ] ], + "fetch-entry" => [ + "comment" => "", + "fields" => [ + "id" => ["type" => "int unsigned", "not null" => "1", "extra" => "auto_increment", "primary" => "1", "comment" => "sequential ID"], + "url" => ["type" => "varbinary(255)", "comment" => "url that awaiting to be fetched"], + "created" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Creation date of the fetch request"], + "wid" => ["type" => "int unsigned", "foreign" => ["workerqueue" => "id"], "comment" => "Workerqueue id"], ], + "indexes" => [ + "PRIMARY" => ["id"], + "url" => ["UNIQUE", "url"], + "created" => ["created"], + "wid" => ["wid"], + ] + ], "fsuggest" => [ "comment" => "friend suggestion stuff", "fields" => [ @@ -783,6 +781,42 @@ return [ "hook_file_function" => ["UNIQUE", "hook", "file", "function"], ] ], + "inbox-entry" => [ + "comment" => "Incoming activity", + "fields" => [ + "id" => ["type" => "int unsigned", "not null" => "1", "extra" => "auto_increment", "primary" => "1", "comment" => "sequential ID"], + "activity-id" => ["type" => "varbinary(255)", "comment" => "id of the incoming activity"], + "object-id" => ["type" => "varbinary(255)", "comment" => ""], + "in-reply-to-id" => ["type" => "varbinary(255)", "comment" => ""], + "conversation" => ["type" => "varbinary(255)", "comment" => ""], + "type" => ["type" => "varchar(64)", "comment" => "Type of the activity"], + "object-type" => ["type" => "varchar(64)", "comment" => "Type of the object activity"], + "object-object-type" => ["type" => "varchar(64)", "comment" => "Type of the object's object activity"], + "received" => ["type" => "datetime", "comment" => "Receiving date"], + "activity" => ["type" => "mediumtext", "comment" => "The JSON activity"], + "signer" => ["type" => "varchar(255)", "comment" => ""], + "push" => ["type" => "boolean", "comment" => "Is the entry pushed or have pulled it?"], + "trust" => ["type" => "boolean", "comment" => "Do we trust this entry?"], + "wid" => ["type" => "int unsigned", "foreign" => ["workerqueue" => "id"], "comment" => "Workerqueue id"], ], + "indexes" => [ + "PRIMARY" => ["id"], + "activity-id" => ["UNIQUE", "activity-id"], + "object-id" => ["object-id"], + "received" => ["received"], + "wid" => ["wid"], + ] + ], + "inbox-entry-receiver" => [ + "comment" => "Receiver for the incoming activity", + "fields" => [ + "queue-id" => ["type" => "int unsigned", "not null" => "1", "primary" => "1", "foreign" => ["inbox-entry" => "id"], "comment" => ""], + "uid" => ["type" => "mediumint unsigned", "not null" => "1", "primary" => "1", "foreign" => ["user" => "uid"], "comment" => "User id"], + ], + "indexes" => [ + "PRIMARY" => ["queue-id", "uid"], + "uid" => ["uid"], + ] + ], "inbox-status" => [ "comment" => "Status of ActivityPub inboxes", "fields" => [ @@ -1119,6 +1153,17 @@ return [ "vid" => ["vid"], ] ], + "post-activity" => [ + "comment" => "Original remote activity", + "fields" => [ + "uri-id" => ["type" => "int unsigned", "not null" => "1", "primary" => "1", "foreign" => ["item-uri" => "id"], "comment" => "Id of the item-uri table entry that contains the item uri"], + "activity" => ["type" => "mediumtext", "comment" => "Original activity"], + "received" => ["type" => "datetime", "comment" => ""], + ], + "indexes" => [ + "PRIMARY" => ["uri-id"], + ] + ], "post-category" => [ "comment" => "post relation to categories", "fields" => [ @@ -1320,6 +1365,7 @@ return [ "comment" => "Thread related data", "fields" => [ "uri-id" => ["type" => "int unsigned", "not null" => "1", "primary" => "1", "foreign" => ["item-uri" => "id"], "comment" => "Id of the item-uri table entry that contains the item uri"], + "conversation-id" => ["type" => "int unsigned", "foreign" => ["item-uri" => "id"], "comment" => "Id of the item-uri table entry that contains the conversation uri"], "owner-id" => ["type" => "int unsigned", "not null" => "1", "default" => "0", "foreign" => ["contact" => "id", "on delete" => "restrict"], "comment" => "Item owner"], "author-id" => ["type" => "int unsigned", "not null" => "1", "default" => "0", "foreign" => ["contact" => "id", "on delete" => "restrict"], "comment" => "Item author"], "causer-id" => ["type" => "int unsigned", "foreign" => ["contact" => "id", "on delete" => "restrict"], "comment" => "Link to the contact table with uid=0 of the contact that caused the item creation"], @@ -1331,6 +1377,7 @@ return [ ], "indexes" => [ "PRIMARY" => ["uri-id"], + "conversation-id" => ["conversation-id"], "owner-id" => ["owner-id"], "author-id" => ["author-id"], "causer-id" => ["causer-id"], @@ -1399,6 +1446,7 @@ return [ "comment" => "Thread related data per user", "fields" => [ "uri-id" => ["type" => "int unsigned", "not null" => "1", "primary" => "1", "foreign" => ["item-uri" => "id"], "comment" => "Id of the item-uri table entry that contains the item uri"], + "conversation-id" => ["type" => "int unsigned", "foreign" => ["item-uri" => "id"], "comment" => "Id of the item-uri table entry that contains the conversation uri"], "owner-id" => ["type" => "int unsigned", "not null" => "1", "default" => "0", "foreign" => ["contact" => "id", "on delete" => "restrict"], "comment" => "Item owner"], "author-id" => ["type" => "int unsigned", "not null" => "1", "default" => "0", "foreign" => ["contact" => "id", "on delete" => "restrict"], "comment" => "Item author"], "causer-id" => ["type" => "int unsigned", "foreign" => ["contact" => "id", "on delete" => "restrict"], "comment" => "Link to the contact table with uid=0 of the contact that caused the item creation"], @@ -1425,6 +1473,7 @@ return [ "indexes" => [ "PRIMARY" => ["uid", "uri-id"], "uri-id" => ["uri-id"], + "conversation-id" => ["conversation-id"], "owner-id" => ["owner-id"], "author-id" => ["author-id"], "causer-id" => ["causer-id"], @@ -1674,6 +1723,28 @@ return [ "uri-id_uid" => ["UNIQUE", "uri-id", "uid"], ] ], + "arrived-activity" => [ + "comment" => "Id of arrived activities", + "fields" => [ + "object-id" => ["type" => "varbinary(255)", "not null" => "1", "primary" => "1", "comment" => "object id of the incoming activity"], + "received" => ["type" => "datetime", "comment" => "Receiving date"], + ], + "indexes" => [ + "PRIMARY" => ["object-id"], + ], + "engine" => "MEMORY", + ], + "processed-activity" => [ + "comment" => "Id of processed activities", + "fields" => [ + "object-id" => ["type" => "varbinary(255)", "not null" => "1", "primary" => "1", "comment" => "object id of the incoming activity"], + "received" => ["type" => "datetime", "comment" => "Receiving date"], + ], + "indexes" => [ + "PRIMARY" => ["object-id"], + ], + "engine" => "MEMORY", + ], "worker-ipc" => [ "comment" => "Inter process communication between the frontend and the worker", "fields" => [