- Bump utopia-php/migration to add-services-migration dev branch
- MigrationReport rule for TYPE_SERVICES
- E2E: testAppwriteMigrationServices disables functions + graphql on
source, runs migration, asserts both land disabled on destination
- Bump utopia-php/migration to add-labels-migration dev branch
- MigrationReport rule for TYPE_LABELS
- E2E: testAppwriteMigrationLabels sets unique labels on source via
console patch, runs migration, asserts destination has matching set
- Bump utopia-php/migration to add-protocols-migration dev branch
- MigrationReport rule for TYPE_PROTOCOLS
- E2E: testAppwriteMigrationProtocols flips graphql + websocket on
source, runs migration, asserts both land disabled on destination
- Bump utopia-php/migration to add-auth-methods-migration dev branch
- Add MigrationReport rule for TYPE_AUTH_METHODS
- E2E: testAppwriteMigrationAuthMethods flips email-password + JWT on
source, runs migration, asserts both land as false on destination
The DELETE_TYPE_TRANSACTION constant was 'transaction' (singular), so
the worker's inner switch on $document->getCollection() (which returns
'transactions') never matched and every transaction deletion fell to
the default branch, logging "No lazy delete operation available for
document of type: transactions". Renamed to DELETE_TYPE_TRANSACTIONS
to align with every other constant used in that switch.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
The sampler reads project.id from the span; realtime and VCS were storing it
under namespaced keys (realtime.project.id, vcs.github.event.repo.{id}.project.id),
causing all those spans to be dropped when _APP_TRACE_PROJECT_ID was set.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Span attribute keys are now snake_case with dots only for child
relationships. Worker span lifecycle moved to app/worker.php; selective
trace filtering moved to the exporter sampler in app/init/span.php so
handlers only call Span::add.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
- Add skipFilters to Reports/Get.php (was the only endpoint still
triggering the full N+1 subquery cascade)
- Scale CTA batch limit dynamically (insightCount * MAX_CTA_COUNT)
instead of fixed APP_LIMIT_SUBQUERY to prevent silent truncation
- Revert deleteReport to callback-based pagination so CTAs are not
orphaned when a report has more than APP_LIMIT_SUBQUERY insights
- Add explicit prefix lengths (700) to _key_project_resource and
_key_project_parent_resource indexes to stay under InnoDB 3072-byte limit
- Validate CTA service/method against ADVISOR_CTA_SERVICES and
ADVISOR_CTA_METHODS enums in the CTAs validator
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Fix N+1 in Reports/XList (51→4 queries) via skipFilters + batch fetch
- Add skipFilters to Reports/Delete and cursor fetch (avoid loading all
nested insights/CTAs just for ownership check)
- Fix N+1 in deleteReport worker (flat CTA deletion instead of per-insight)
- Add advisor entity cleanup on project deletion (reports, insights, CTAs)
- Remove resourceInternalId, parentResourceInternalId, $permissions from
Insight response model (internal IDs leak DB internals, permissions unused)
- Remove dead subQueryInsightCTAs filter registration
- Remove stale enum-value comments from platform schema
- Fix _key_dismissedAt index to include projectInternalId
- Fix scope category from 'Other' to 'Advisor'
- Switch action base class from Utopia\Platform\Action to Appwrite\Platform\Action
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Promises\Swoole was already propagating the request container into child
coroutines, but using its own pre-existing key (__utopia_http_request_container)
rather than the new utopia-php/http key (__utopia__). With the keys
mismatched, the propagation was dead code and resolvers spawned from
webonyx coroutines saw an empty context, failing every GraphQL query
with 'Dependency utopia:graphql not found'.
Align the key so child coroutines actually inherit the request's
container (wrapped as a child Container, so request-scoped overrides
in the resolver can't bleed back into the outer request).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
EVENT_START and EVENT_TASK were each constructing `new Http($swoole, 'UTC')`
purely as a vehicle to reach DI -- never configuring routing, never calling
->run(). Now that the Swoole adapter exposes resources() directly, the
Http instance is no longer needed: the resources container we passed into
the Server constructor is already in scope as $container.
Drop the throwaway Http construction, pass $container straight through, and
update createDatabase() to take Container instead of Http to match. Also
rename $swooleAdapter to $swoole for consistency with the rest of the file.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adopts the new split DI containers in utopia-php/http: `resources()` for
boot-time wiring (shared across requests) and `context()` for per-request
state. Replaces the removed `getResource()`/`setResource()`/`getContainer()`
helpers throughout the HTTP entry point, controllers, GraphQL layer, and
installer.
Bumps the dependency chain accordingly: utopia-php/http to the dev branch
(aliased to 0.34.25 to satisfy platform's exact pin), servers 0.4.*,
queue 0.18.*, and pulled-along cli/platform/database upgrades.
Also tightens app/init/resources/request.php by collapsing single-return
factories to arrow functions.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Event::generateEvents() rejects the pattern 'project.delete' because
it parses 'delete' as a resource that must be present in route params.
The pre-migration route did not declare an event label, so functions
and webhooks were never triggered on project deletion. Restore that
behavior by removing the label.