use Friendica\Database\DBA;
if (!defined('DB_UPDATE_VERSION')) {
- define('DB_UPDATE_VERSION', 1430);
+ define('DB_UPDATE_VERSION', 1434);
}
return [
"about" => ["type" => "text", "comment" => ""],
"keywords" => ["type" => "text", "comment" => "public keywords (interests) of the contact"],
"gender" => ["type" => "varchar(32)", "not null" => "1", "default" => "", "comment" => "Deprecated"],
- "xmpp" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
+ "xmpp" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => "XMPP address"],
+ "matrix" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => "Matrix address"],
"attag" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
"avatar" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
"photo" => ["type" => "varchar(255)", "default" => "", "comment" => "Link to the profile photo of the contact"],
"nick" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
"name" => ["type" => "varchar(255)", "comment" => ""],
"about" => ["type" => "text", "comment" => ""],
+ "xmpp" => ["type" => "varchar(255)", "comment" => "XMPP address"],
+ "matrix" => ["type" => "varchar(255)", "comment" => "Matrix address"],
"photo" => ["type" => "varchar(255)", "comment" => ""],
"header" => ["type" => "varchar(255)", "comment" => "Header picture"],
"addr" => ["type" => "varchar(255)", "comment" => ""],
"received" => ["received"],
]
],
+ "workerqueue" => [
+ "comment" => "Background tasks queue entries",
+ "fields" => [
+ "id" => ["type" => "int unsigned", "not null" => "1", "extra" => "auto_increment", "primary" => "1", "comment" => "Auto incremented worker task id"],
+ "command" => ["type" => "varchar(100)", "comment" => "Task command"],
+ "parameter" => ["type" => "mediumtext", "comment" => "Task parameter"],
+ "priority" => ["type" => "tinyint unsigned", "not null" => "1", "default" => "0", "comment" => "Task priority"],
+ "created" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Creation date"],
+ "pid" => ["type" => "int unsigned", "not null" => "1", "default" => "0", "comment" => "Process id of the worker"],
+ "executed" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Execution date"],
+ "next_try" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Next retrial date"],
+ "retrial" => ["type" => "tinyint", "not null" => "1", "default" => "0", "comment" => "Retrial counter"],
+ "done" => ["type" => "boolean", "not null" => "1", "default" => "0", "comment" => "Marked 1 when the task was done - will be deleted later"],
+ ],
+ "indexes" => [
+ "PRIMARY" => ["id"],
+ "command" => ["command"],
+ "done_command_parameter" => ["done", "command", "parameter(64)"],
+ "done_executed" => ["done", "executed"],
+ "done_priority_retrial_created" => ["done", "priority", "retrial", "created"],
+ "done_priority_next_try" => ["done", "priority", "next_try"],
+ "done_pid_next_try" => ["done", "pid", "next_try"],
+ "done_pid_retrial" => ["done", "pid", "retrial"],
+ "done_pid_priority_created" => ["done", "pid", "priority", "created"]
+ ]
+ ],
"delayed-post" => [
"comment" => "Posts that are about to be distributed at a later time",
"fields" => [
"uri" => ["type" => "varchar(255)", "comment" => "URI of the post that will be distributed later"],
"uid" => ["type" => "mediumint unsigned", "foreign" => ["user" => "uid"], "comment" => "Owner User id"],
"delayed" => ["type" => "datetime", "comment" => "delay time"],
+ "wid" => ["type" => "int unsigned", "foreign" => ["workerqueue" => "id"], "comment" => "Workerqueue id"],
],
"indexes" => [
"PRIMARY" => ["id"],
"uid_uri" => ["UNIQUE", "uid", "uri(190)"],
+ "wid" => ["wid"],
]
],
"diaspora-interaction" => [
"education" => ["type" => "text", "comment" => "Deprecated"],
"contact" => ["type" => "text", "comment" => "Deprecated"],
"homepage" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
- "xmpp" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
+ "xmpp" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => "XMPP address"],
+ "matrix" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => "Matrix address"],
"photo" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
"thumb" => ["type" => "varchar(255)", "not null" => "1", "default" => "", "comment" => ""],
"publish" => ["type" => "boolean", "not null" => "1", "default" => "0", "comment" => "publish default profile in local directory"],
"PRIMARY" => ["id"]
]
],
+ "subscription" => [
+ "comment" => "Push Subscription for the API",
+ "fields" => [
+ "id" => ["type" => "int unsigned", "not null" => "1", "extra" => "auto_increment", "primary" => "1", "comment" => "Auto incremented image data id"],
+ "application-id" => ["type" => "int unsigned", "not null" => "1", "foreign" => ["application" => "id"], "comment" => ""],
+ "uid" => ["type" => "mediumint unsigned", "not null" => "1", "foreign" => ["user" => "uid"], "comment" => "Owner User id"],
+ "endpoint" => ["type" => "varchar(511)", "comment" => "Endpoint URL"],
+ "pubkey" => ["type" => "varchar(127)", "comment" => "User agent public key"],
+ "secret" => ["type" => "varchar(32)", "comment" => "Auth secret"],
+ "follow" => ["type" => "boolean", "comment" => ""],
+ "favourite" => ["type" => "boolean", "comment" => ""],
+ "reblog" => ["type" => "boolean", "comment" => ""],
+ "mention" => ["type" => "boolean", "comment" => ""],
+ "poll" => ["type" => "boolean", "comment" => ""],
+ "follow_request" => ["type" => "boolean", "comment" => ""],
+ "status" => ["type" => "boolean", "comment" => ""],
+ ],
+ "indexes" => [
+ "PRIMARY" => ["id"],
+ "application-id_uid" => ["UNIQUE", "application-id", "uid"],
+ "uid_application-id" => ["uid", "application-id"],
+ ]
+ ],
"userd" => [
"comment" => "Deleted usernames",
"fields" => [
],
"engine" => "MEMORY",
],
- "workerqueue" => [
- "comment" => "Background tasks queue entries",
- "fields" => [
- "id" => ["type" => "int unsigned", "not null" => "1", "extra" => "auto_increment", "primary" => "1", "comment" => "Auto incremented worker task id"],
- "command" => ["type" => "varchar(100)", "comment" => "Task command"],
- "parameter" => ["type" => "mediumtext", "comment" => "Task parameter"],
- "priority" => ["type" => "tinyint unsigned", "not null" => "1", "default" => "0", "comment" => "Task priority"],
- "created" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Creation date"],
- "pid" => ["type" => "int unsigned", "not null" => "1", "default" => "0", "comment" => "Process id of the worker"],
- "executed" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Execution date"],
- "next_try" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Next retrial date"],
- "retrial" => ["type" => "tinyint", "not null" => "1", "default" => "0", "comment" => "Retrial counter"],
- "done" => ["type" => "boolean", "not null" => "1", "default" => "0", "comment" => "Marked 1 when the task was done - will be deleted later"],
- ],
- "indexes" => [
- "PRIMARY" => ["id"],
- "command" => ["command"],
- "done_command_parameter" => ["done", "command", "parameter(64)"],
- "done_executed" => ["done", "executed"],
- "done_priority_retrial_created" => ["done", "priority", "retrial", "created"],
- "done_priority_next_try" => ["done", "priority", "next_try"],
- "done_pid_next_try" => ["done", "pid", "next_try"],
- "done_pid_retrial" => ["done", "pid", "retrial"],
- "done_pid_priority_created" => ["done", "pid", "priority", "created"]
- ]
- ],
];