diff --git a/app/config/specs/open-api3-latest-client.json b/app/config/specs/open-api3-latest-client.json index 232861f0ff..820b1f55e0 100644 --- a/app/config/specs/open-api3-latest-client.json +++ b/app/config/specs/open-api3-latest-client.json @@ -6361,6 +6361,7 @@ "gif", "png", "webp", + "heic", "avif" ], "x-enum-name": "ImageFormat", diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index 42ed7b9d28..1390319703 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -25157,6 +25157,7 @@ "gif", "png", "webp", + "heic", "avif" ], "x-enum-name": "ImageFormat", @@ -35706,6 +35707,18 @@ "x-example": 0, "format": "int32" }, + "databasesReadsTotal": { + "type": "integer", + "description": "Total number of databases reads.", + "x-example": 0, + "format": "int32" + }, + "databasesWritesTotal": { + "type": "integer", + "description": "Total number of databases writes.", + "x-example": 0, + "format": "int32" + }, "databases": { "type": "array", "description": "Aggregated number of databases per period.", @@ -35737,6 +35750,22 @@ "$ref": "#\/components\/schemas\/metric" }, "x-example": [] + }, + "databasesReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "databasesWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] } }, "required": [ @@ -35745,10 +35774,14 @@ "collectionsTotal", "documentsTotal", "storageTotal", + "databasesReadsTotal", + "databasesWritesTotal", "databases", "collections", "documents", - "storage" + "storage", + "databasesReads", + "databasesWrites" ] }, "usageDatabase": { @@ -35778,6 +35811,18 @@ "x-example": 0, "format": "int32" }, + "databaseReadsTotal": { + "type": "integer", + "description": "Total number of databases reads.", + "x-example": 0, + "format": "int32" + }, + "databaseWritesTotal": { + "type": "integer", + "description": "Total number of databases writes.", + "x-example": 0, + "format": "int32" + }, "collections": { "type": "array", "description": "Aggregated number of collections per period.", @@ -35801,6 +35846,22 @@ "$ref": "#\/components\/schemas\/metric" }, "x-example": [] + }, + "databaseReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "databaseWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] } }, "required": [ @@ -35808,9 +35869,13 @@ "collectionsTotal", "documentsTotal", "storageTotal", + "databaseReadsTotal", + "databaseWritesTotal", "collections", "documents", - "storage" + "storage", + "databaseReads", + "databaseWrites" ] }, "usageCollection": { @@ -36405,6 +36470,18 @@ "x-example": 0, "format": "int32" }, + "databasesReadsTotal": { + "type": "integer", + "description": "Total number of databases reads.", + "x-example": 0, + "format": "int32" + }, + "databasesWritesTotal": { + "type": "integer", + "description": "Total number of databases writes.", + "x-example": 0, + "format": "int32" + }, "requests": { "type": "array", "description": "Aggregated number of requests per period.", @@ -36504,6 +36581,22 @@ "$ref": "#\/components\/schemas\/metricBreakdown" }, "x-example": [] + }, + "databasesReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "databasesWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] } }, "required": [ @@ -36519,6 +36612,8 @@ "bucketsTotal", "executionsMbSecondsTotal", "buildsMbSecondsTotal", + "databasesReadsTotal", + "databasesWritesTotal", "requests", "network", "users", @@ -36531,7 +36626,9 @@ "functionsStorageBreakdown", "authPhoneTotal", "authPhoneEstimate", - "authPhoneCountryBreakdown" + "authPhoneCountryBreakdown", + "databasesReads", + "databasesWrites" ] }, "headers": { diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index aee66626cf..aec14113b6 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -17577,6 +17577,7 @@ "gif", "png", "webp", + "heic", "avif" ], "x-enum-name": "ImageFormat", diff --git a/app/config/specs/swagger2-latest-client.json b/app/config/specs/swagger2-latest-client.json index 5369cd4c92..c0980c44ce 100644 --- a/app/config/specs/swagger2-latest-client.json +++ b/app/config/specs/swagger2-latest-client.json @@ -6560,6 +6560,7 @@ "gif", "png", "webp", + "heic", "avif" ], "x-enum-name": "ImageFormat", diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index f9a423d954..d57385c56e 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -25633,6 +25633,7 @@ "gif", "png", "webp", + "heic", "avif" ], "x-enum-name": "ImageFormat", @@ -36243,6 +36244,18 @@ "x-example": 0, "format": "int32" }, + "databasesReadsTotal": { + "type": "integer", + "description": "Total number of databases reads.", + "x-example": 0, + "format": "int32" + }, + "databasesWritesTotal": { + "type": "integer", + "description": "Total number of databases writes.", + "x-example": 0, + "format": "int32" + }, "databases": { "type": "array", "description": "Aggregated number of databases per period.", @@ -36278,6 +36291,24 @@ "$ref": "#\/definitions\/metric" }, "x-example": [] + }, + "databasesReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "databasesWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] } }, "required": [ @@ -36286,10 +36317,14 @@ "collectionsTotal", "documentsTotal", "storageTotal", + "databasesReadsTotal", + "databasesWritesTotal", "databases", "collections", "documents", - "storage" + "storage", + "databasesReads", + "databasesWrites" ] }, "usageDatabase": { @@ -36319,6 +36354,18 @@ "x-example": 0, "format": "int32" }, + "databaseReadsTotal": { + "type": "integer", + "description": "Total number of databases reads.", + "x-example": 0, + "format": "int32" + }, + "databaseWritesTotal": { + "type": "integer", + "description": "Total number of databases writes.", + "x-example": 0, + "format": "int32" + }, "collections": { "type": "array", "description": "Aggregated number of collections per period.", @@ -36345,6 +36392,24 @@ "$ref": "#\/definitions\/metric" }, "x-example": [] + }, + "databaseReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "databaseWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] } }, "required": [ @@ -36352,9 +36417,13 @@ "collectionsTotal", "documentsTotal", "storageTotal", + "databaseReadsTotal", + "databaseWritesTotal", "collections", "documents", - "storage" + "storage", + "databaseReads", + "databaseWrites" ] }, "usageCollection": { @@ -36976,6 +37045,18 @@ "x-example": 0, "format": "int32" }, + "databasesReadsTotal": { + "type": "integer", + "description": "Total number of databases reads.", + "x-example": 0, + "format": "int32" + }, + "databasesWritesTotal": { + "type": "integer", + "description": "Total number of databases writes.", + "x-example": 0, + "format": "int32" + }, "requests": { "type": "array", "description": "Aggregated number of requests per period.", @@ -37086,6 +37167,24 @@ "$ref": "#\/definitions\/metricBreakdown" }, "x-example": [] + }, + "databasesReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "databasesWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] } }, "required": [ @@ -37101,6 +37200,8 @@ "bucketsTotal", "executionsMbSecondsTotal", "buildsMbSecondsTotal", + "databasesReadsTotal", + "databasesWritesTotal", "requests", "network", "users", @@ -37113,7 +37214,9 @@ "functionsStorageBreakdown", "authPhoneTotal", "authPhoneEstimate", - "authPhoneCountryBreakdown" + "authPhoneCountryBreakdown", + "databasesReads", + "databasesWrites" ] }, "headers": { diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index a3c6a0d70c..98ebfa6116 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -18034,6 +18034,7 @@ "gif", "png", "webp", + "heic", "avif" ], "x-enum-name": "ImageFormat", diff --git a/src/Appwrite/Utopia/Response/Model/UsageDatabase.php b/src/Appwrite/Utopia/Response/Model/UsageDatabase.php index d6afa02f65..a0fe421f5f 100644 --- a/src/Appwrite/Utopia/Response/Model/UsageDatabase.php +++ b/src/Appwrite/Utopia/Response/Model/UsageDatabase.php @@ -70,14 +70,16 @@ class UsageDatabase extends Model ->addRule('databaseReads', [ 'type' => Response::MODEL_METRIC, 'description' => 'An array of aggregated number of database reads.', - 'default' => 0, - 'example' => 0, + 'default' => [], + 'example' => [], + 'array' => true ]) ->addRule('databaseWrites', [ 'type' => Response::MODEL_METRIC, 'description' => 'An array of aggregated number of database writes.', - 'default' => 0, - 'example' => 0, + 'default' => [], + 'example' => [], + 'array' => true ]) ; } diff --git a/src/Appwrite/Utopia/Response/Model/UsageDatabases.php b/src/Appwrite/Utopia/Response/Model/UsageDatabases.php index a9c8e5fada..4e053e5223 100644 --- a/src/Appwrite/Utopia/Response/Model/UsageDatabases.php +++ b/src/Appwrite/Utopia/Response/Model/UsageDatabases.php @@ -83,14 +83,16 @@ class UsageDatabases extends Model ->addRule('databasesReads', [ 'type' => Response::MODEL_METRIC, 'description' => 'An array of aggregated number of database reads.', - 'default' => 0, - 'example' => 0, + 'default' => [], + 'example' => [], + 'array' => true ]) ->addRule('databasesWrites', [ 'type' => Response::MODEL_METRIC, 'description' => 'An array of aggregated number of database writes.', - 'default' => 0, - 'example' => 0, + 'default' => [], + 'example' => [], + 'array' => true ]) ; } diff --git a/src/Appwrite/Utopia/Response/Model/UsageProject.php b/src/Appwrite/Utopia/Response/Model/UsageProject.php index ff4106eaed..1006276b56 100644 --- a/src/Appwrite/Utopia/Response/Model/UsageProject.php +++ b/src/Appwrite/Utopia/Response/Model/UsageProject.php @@ -186,14 +186,16 @@ class UsageProject extends Model ->addRule('databasesReads', [ 'type' => Response::MODEL_METRIC, 'description' => 'An array of aggregated number of database reads.', - 'default' => 0, - 'example' => 0, + 'default' => [], + 'example' => [], + 'array' => true ]) ->addRule('databasesWrites', [ 'type' => Response::MODEL_METRIC, 'description' => 'An array of aggregated number of database writes.', - 'default' => 0, - 'example' => 0, + 'default' => [], + 'example' => [], + 'array' => true ]) ; }