Skip to content

fix(executions): stop creating MySQL collection - #13699

Merged
TorstenDittmann merged 3 commits into
mainfrom
torsten/remove-executions-schema-048b
Sep 15, 2026
Merged

TorstenDittmann merged 3 commits into
mainfrom
torsten/remove-executions-schema-048b

Conversation

@TorstenDittmann

@TorstenDittmann TorstenDittmann commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

What does this PR do?

Removes the executions schema from app/config/collections/projects.php. ClickHouse is the only execution store, so new CE project databases must no longer run createCollection('executions').

Execution and site-log query validators previously derived their public query field types from this physical MySQL schema. Executions now owns the local ClickHouse execution attribute types and validator stack; Logs reuses it with its narrower allowlist. The shared query Base remains unchanged.

This does not drop existing tables and does not run any migration or deployment. Existing Cloud tables remain the job of appwrite-labs/cloud#5821, which already unsets the CE entry as a temporary companion safeguard.

Test Plan

  • tests/unit/General/CollectionsTest.php asserts function execution and site log status queries still validate without the removed schema.
  • Verified the PR leaves Queries/Base.php unchanged.
  • Verified the committed diff has no whitespace errors.
  • Verified projects.php has no executions collection key and no query validator still requests that physical schema.
  • PHP/Composer are unavailable in this agent environment; CI runs the unit and formatting suites.

Related PRs and Issues

Checklist

  • Have you read the Contributing Guidelines on issues?
  • If the PR includes a change to an API's metadata (desc, label, params, etc.), does it also include updated API specs and example docs? (No API metadata changed.)
Open in Web Open in Cursor 

Remove the project-database executions schema now that ClickHouse is the
only execution store. Keep execution and site-log query validation
independent from the physical MySQL collection definition.

Co-authored-by: Torsten Dittmann <[email protected]>
@TorstenDittmann
TorstenDittmann marked this pull request as ready for review September 15, 2026 09:43
@greptile-apps

greptile-apps Bot commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

The code change appears safe to merge. The open test concern is non-blocking.

Fix All in Claude CodeFindings

  1. P2 testProjectsDoNotDefineExecutionsCollection only checks the shape of collections . It does not prove that project setup skips the MySQL collection. The repository rule says tests must cover observable behavior and must not mirror source code or configuration. Replace this with a test that creates a project and checks that its MySQL database has no executions collection. ▶
Fix with agent prompt
### Issue 1
tests/unit/General/CollectionsTest.php:40-43
`testProjectsDoNotDefineExecutionsCollection` only checks the shape of `collections`. It does not prove that project setup skips the MySQL collection. The repository rule says tests must cover observable behavior and must not mirror source code or configuration. Replace this with a test that creates a project and checks that its MySQL database has no `executions` collection.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Summary

New CE projects no longer create a MySQL executions collection because execution data is stored in ClickHouse. Query validation keeps working by defining execution fields directly in the validators instead of reading the removed schema.

  • Removes the executions collection from project setup.
  • Keeps execution and site-log query validation independent of that collection.

Reviews (3) · Last reviewed commit: "fix(executions): localize query attribut..."

Comment thread tests/unit/General/CollectionsTest.php Resolved
@github-actions

github-actions Bot commented Sep 15, 2026 •

Copy link
Copy Markdown

✨ Benchmark results

Comparing main (before) → torsten/remove-executions-schema-048b (after).

Metric Before After Change
🚀 Requests/sec 249.61 256.05 ⚪ +2.6%
⏱️ Latency P50 70.58 ms 68.84 ms ⚪ -2.5%
⏱️ Latency P95 160.92 ms 155.32 ms ⚪ -3.5%
Per-scenario breakdown & investigation details

Metrics below reflect the current branch (after). Δ P95 compares against the base.

Scenario P50 (ms) P95 (ms) Requests RPS Δ P95 (ms)
API total 68.84 155.32 15,903 256.05 -5.59
Account 129.86 228.92 837 13.9 -21.51
TablesDB 66.48 118.82 8,649 140.75 -5.38
Storage 63.47 137.2 4,185 70.21 -5.48
Functions 97.43 185.33 2,232 38.12 -12.46

Top API waits (after)

API request Max wait (ms)
account.prefs.update 432.74
functions.variables.create 367.27
account.name.update 356.8
storage.buckets.create 311.44
functions.variables.update 311.13

@TorstenDittmann
TorstenDittmann merged commit 256b080 into main Sep 15, 2026
47 checks passed
@TorstenDittmann
TorstenDittmann deleted the torsten/remove-executions-schema-048b branch September 15, 2026 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants