I'm running a self-hosted instance of Appwrite integrated with Sentry to track errors. The following error trace is very frequent. Based on the trace, it seems like it is something related to createOrUpdateMetric
#1 /usr/src/code/vendor/utopia-php/database/src/Database/Database.php(2626): Utopia\Database\Adapter\MariaDB->createDocument('stats', Object(Utopia\Database\Document))
#2 /usr/src/code/src/Appwrite/Usage/Calculators/TimeSeries.php(439): Utopia\Database\Database->createDocument(Object(Utopia\Database\Document), Object(Utopia\Database\Document))
#3 /usr/src/code/src/Appwrite/Usage/Calculators/TimeSeries.php(521): Appwrite\Usage\Calculators\TimeSeries->createOrUpdateMetric('64f0d151afbeeea...', '2023-09-02T18:0...', '1h', 'users.$all.coun...', -1, 0)
#4 /usr/src/code/src/Appwrite/Usage/Calculators/TimeSeries.php(546): Appwrite\Usage\Calculators\TimeSeries->syncFromInfluxDB('users.$all.coun...', Array, Array)
#5 /usr/src/code/src/Appwrite/Platform/Tasks/Usage.php(53): Appwrite\Usage\Calculators\TimeSeries->collect()
#6 /usr/src/code/vendor/utopia-php/cli/src/CLI/Console.php(219): Appwrite\Platform\Tasks\Usage->Appwrite\Platform\Tasks\{closure}()
#7 /usr/src/code/src/Appwrite/Platform/Tasks/Usage.php(58): Utopia\CLI\Console::loop(Object(Closure), 30)
#8 /usr/src/code/src/Appwrite/Platform/Tasks/Usage.php(30): Appwrite\Platform\Tasks\Usage->action(Object(Utopia\Database\Database), Object(InfluxDB\Database), Object(Utopia\Registry\Registry), Object(Closure), Object(Closure))
#9 /usr/src/code/vendor/utopia-php/cli/src/CLI/CLI.php(320): Appwrite\Platform\Tasks\Usage->Appwrite\Platform\Tasks\{closure}(Object(Utopia\Database\Database), Object(InfluxDB\Database), Object(Utopia\Registry\Registry), Object(Closure), Object(Closure))
#10 /usr/src/code/app/cli.php(195): Utopia\CLI\CLI->run()
#11 {main}```
yes....we have problems with usage and have planned to release a rewrite.
related issue: https://github.com/appwrite/appwrite/issues/4751
Recommended threads
- Impossible to create project via CLI?
Is it possible to create a new project via the appwrite CLI ? I need to create a few projects for something I'm working on and because i don't want to do it man...
- Understanding S3 setup with appwrite
Hey, i'm planning to change the storage from local to S3, tho i have some questions to see before starting the migration. 1. Does all the `/storage/<storage_ty...
- S3 files like health6a079a79afaa25.44072...
I migrated to another external S3 host for my appwrite and in many (but not all) folders a file (something like health6a079a79afaa25.44072323 - file itself is e...