Repository navigation
chore(avatars): report photo storage through unified storage - #14129
Merged
Merged
Conversation
The per-service storage metrics are deprecated in favour of the unified storage metric split by resourceType. Write photo bytes there under the photos resourceType and drop avatars.storage. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
lohanidamodar
approved these changes
Oct 5, 2026
🔵 Tier A · Mergeable after minor fixes
Photo storage is now emitted as the unified
Fix with agent prompt### Issue 1
src/Appwrite/Platform/Workers/StatsResources.php:290
**Cover photo storage attribution through the usage API**
The existing usage E2E suite tests gauge queries, but no test covers this changed metric contract. Please add a regression that uploads a photo and polls `storage` filtered by `service: avatars` and `resourceType: photos`, asserting the reported bytes so a metric or tag regression cannot silently hide photo usage.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.📂 Walkthrough · 3
Reviewed |
ghost
approved these changes
Oct 5, 2026
✨ Benchmark resultsComparing
Per-scenario breakdown & investigation detailsMetrics below reflect the current branch (after). Δ P95 compares against the base.
Top API waits (after)
|
abnegate
added a commit
that referenced
this pull request
Oct 5, 2026
Merges main a2cca78 (#14009, #14106, #14117, #14115, #14119, #14114, #14101, #14125, #14129, #14127) so cloud#5410 can require a train head that contains main at or after 0ed7232. Conflicts: none. Database 8.0 port: none needed. Main's new code only uses Document getAttribute/setAttribute and Query::equal/lessThan/orderAsc/limit (Tasks/Interval.php), all unchanged in database 8.0; no removed Database::* constants, config collections, or model magic reads. composer.json and composer.lock are untouched by main, so the train's database and migration pins stay as they are. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Follow-up to #13949. Per review on appwrite-labs/cloud#6169, the per-service
*.storagemetrics are deprecated in favour of the unifiedstoragemetric split byresourceType.StatsResourceswrites photo bytes (sum ofusers.photoSize) asstoragewithresourceType: photosandservice: avatars, instead ofavatars.storage.METRIC_AVATARS_STORAGEis removed fromapp/init/constants.phpand from theStatsUsageskip list. Nothing reads it.Test Plan
php -land Pint pass on the changed files.avatars.storage. CI runs the full suite.🤖 Generated with Claude Code