]> git.mxchange.org Git - friendica.git/blobdiff - static/dbstructure.config.php
Blanks replaced
[friendica.git] / static / dbstructure.config.php
index 41758ed4b411a2d8a47990aed9bdf86f5d6cf843..44b2fc1f80fa5dff06e35e0799aab91dd25fe983 100644 (file)
@@ -55,7 +55,7 @@
 use Friendica\Database\DBA;
 
 if (!defined('DB_UPDATE_VERSION')) {
-       define('DB_UPDATE_VERSION', 1460);
+       define('DB_UPDATE_VERSION', 1462);
 }
 
 return [
@@ -772,6 +772,7 @@ return [
                "comment" => "Status of ActivityPub inboxes",
                "fields" => [
                        "url" => ["type" => "varbinary(255)", "not null" => "1", "primary" => "1", "comment" => "URL of the inbox"],
+                       "uri-id" => ["type" => "int unsigned", "foreign" => ["item-uri" => "id"], "comment" => "Item-uri id of inbox url"],
                        "created" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Creation date of this entry"],
                        "success" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Date of the last successful delivery"],
                        "failure" => ["type" => "datetime", "not null" => "1", "default" => DBA::NULL_DATETIME, "comment" => "Date of the last failed delivery"],
@@ -780,7 +781,8 @@ return [
                        "shared" => ["type" => "boolean", "not null" => "1", "default" => "0", "comment" => "Is it a shared inbox?"]
                ],
                "indexes" => [
-                       "PRIMARY" => ["url"]
+                       "PRIMARY" => ["url"],
+                       "uri-id" => ["uri-id"],
                ]
        ],
        "intro" => [
@@ -1112,8 +1114,8 @@ return [
                ],
                "indexes" => [
                        "PRIMARY" => ["uri-id", "uid", "type", "tid"],
-                       "uri-id" => ["tid"],
-                       "uid" => ["uid"],
+                       "tid" => ["tid"],
+                       "uid_uri-id" => ["uid", "uri-id"],
                ]
        ],
        "post-collection" => [
@@ -1155,6 +1157,23 @@ return [
                        "title-content-warning-body" => ["FULLTEXT", "title", "content-warning", "body"],
                ]
        ],
+       "post-delivery" => [
+               "comment" => "Delivery data for posts for the batch processing",
+               "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"],
+                       "inbox-id" => ["type" => "int unsigned", "not null" => "1", "primary" => "1", "foreign" => ["item-uri" => "id"], "comment" => "Item-uri id of inbox url"],
+                       "uid" => ["type" => "mediumint unsigned", "foreign" => ["user" => "uid"], "comment" => "Delivering user"],
+                       "created" => ["type" => "datetime", "default" => DBA::NULL_DATETIME, "comment" => ""],
+                       "command" => ["type" => "varbinary(32)", "comment" => ""],
+                       "failed" => ["type" => "tinyint", "default" => 0, "comment" => "Number of times the delivery has failed"],
+                       "receivers" => ["type" => "mediumtext", "comment" => "JSON encoded array with the receiving contacts"],
+               ],
+               "indexes" => [
+                       "PRIMARY" => ["uri-id", "inbox-id"],
+                       "inbox-id_created" => ["inbox-id", "created"],
+                       "uid" => ["uid"],
+               ]
+       ],
        "post-delivery-data" => [
                "comment" => "Delivery data for items",
                "fields" => [
@@ -1213,6 +1232,7 @@ return [
                "indexes" => [
                        "PRIMARY" => ["id"],
                        "uri-id-url" => ["UNIQUE", "uri-id", "url"],
+                       "uri-id-id" => ["uri-id", "id"],
                ]
        ],
        "post-question" => [