Repository navigation
Conversation
…n-targets-20260930
…n-targets-20260930 # Conflicts: # CHANGELOG.md # Cargo.lock # Cargo.toml # MIGRATION.md # crates/graphql-orm-macros/Cargo.toml # crates/graphql-orm-macros/README.md # crates/graphql-orm/Cargo.toml # crates/graphql-orm/README.md # crates/graphql-orm/tests/fixtures/backend-coexistence/Cargo.lock # crates/graphql-orm/tests/fixtures/federation-end-to-end/Cargo.lock # crates/graphql-orm/tests/fixtures/migration-api-compatibility/Cargo.lock # crates/graphql-orm/tests/fixtures/repository-aggregate-consumer/Cargo.lock # docs/reference/workspace-packages.md
…datetime defaults
|
Version coordination: independent repository host timestamp PR #109 is open at efa2cd9, based directly on main 809d894. It proposes aligned ORM/macros 0.37.0, leaving this PR's 0.36.0 untouched. It neither depends on nor implements A–D. Timestamp fields remain Integer with unchanged physical/default metadata; approved DateTime rejection semantics are unchanged. SQLite/PostgreSQL no-op regressions passed. Before merging the later branch, reconcile versions/inventory/locks and rerun combined owned backend lanes after rebase, preserving both independent scopes. No workspace release identity was assigned or release published for #109. Broader target-gating (#89) and pre-existing expired documentation review dates (#108) remain separate. |
|
Version coordination for the accepted independent RepositoryEntity host-timestamp capability: #109 now incorporates reviewed main |
Runtime hosts can convert a validated schema into the existing canonical physical migration target without leaked static index storage, preview scoped changes without writes, then separately apply a reviewed immutable plan. Explicit managed ownership bounds DDL; static/system composition and full incoming-FK checks establish the physical dependency environment for later runtime mutations.
Reconciled with current released main while preserving the approved A contract:
df474c761c4057cb643e27a6582dd0376f56e31f(released ORM/macros 0.39.0).e41866d582c36fd920044f6461cb15c6bd446f17.f2665ce68ed7fdbccb272cb8a783b6379ae5fd82.[skip ci]; Actions are paused and hosted checks for this head are not run.The legacy
MigrationStepremains a real enum, with variant/glob imports, qualified constructors, exhaustive matches, inferred values, struct literals and function pointers supported. Static/owned storage borrows into one validation, hash, diff, risk, rendering and application engine. No replacement IR or SQL engine is added.Owned validation/planning is read-only.
apply_owned_migrationenforces explicit ownership, backend/target/plan integrity, destructive/additive guards and a pinned transactional baseline recheck. DDL/history commit together. Existing PostgreSQL RLS flags, policies, owners/grants, helper functions and unrelated system objects are preserved; owned apply does not reconcile an empty RLS target. SQLite rebuilds fail closed for preservation cases the physical model cannot retain, including relevant unsupported incoming FK actions/update semantics/deferral from system or unowned sources. Rechecks occur inside apply. Unsupported live index/default semantics remain structured diagnostics.The approved legacy DateTime default correction is unchanged: static legacy epoch-second DateTime defaults reject conversion; Integer epoch-second defaults remain supported; canonical runtime DateTime defaults remain canonical text/native timestamps. The new cross-slice test converts released repository host-managed Integer timestamps (including a physical
updated_atalias), preserves explicit and implicit defaults/hash, applies the static target, then proves owned no-op replanning and environment certification on both owned backends.Public host example
Compiled example:
crates/graphql-orm/examples/runtime_owned_migration.rs(owned SQLite memory database, preview by default,--applycommits and replans to no-op). PostgreSQL execution and composed system/journal dependencies are covered byruntime_migrations.R3 correction
The minimal PostgreSQL owned DateTime collection reproduced the review failure before the fix: successful apply followed by a Risky
timestamp with time zone→TIMESTAMPTZalteration. The shared static/owned planner now equates those unmodified PostgreSQL built-in spellings. Physical metadata, hashes, defaults and storage semantics are unchanged. Timestamp without time zone, precision modifiers, arrays and qualified/quoted names remain distinct; this is a bounded alias comparison, not arbitrary type normalization.Executable SQLite/PostgreSQL tests cover required and nullable DateTime fields, no default and
CurrentTimestamp, minimal and composed static/runtime targets, plan/apply/no-op and mutation-environment certification. A pure static-planner regression checks both alias directions, unchanged spelling-sensitive hashes and genuine type changes. No supported DateTime fields are rejected to avoid the failure.R3 verification at
f2665ce68ed7fdbccb272cb8a783b6379ae5fd82:--apply, then verified no-op replanning and certification. Release-manifest tests: 6 passed; router notice tests: 13 passed.R3 reran the focused commands below, plus
cargo check/trees for each backend and SQLite+MSSQL. The SQLite migration command includes the new DateTime cases; the PostgreSQL combined command includes them too. Every command usesCARGO_BUILD_JOBS=2, disk scratch and sequential backend builds. PostgreSQL tests verify test-owned container identity before cleanup. The earlier full SQLite/all-target run below was at the preceding head and is not represented as rerun for R3. No new public API, schema migration, automatic DDL or hash-format change is required.R3 fixes the shared planner only; it does not certify B or implement B–D. #112 is still open at
01d4134da18028ec58e318e0ffd30ab244d0d8e1; owner merge/release of #112 should precede A’s final reconciliation against its actual merged revision. Hosted checks for the R3 head are not run while Actions is paused. Both merge and publication remain owner gates.Previous reconciliation verification
The previous reconciliation checks below passed at
75765e71610dbc9a4fb6de6cceeda5b6d7a590f1. These earlier broad results are retained as historical evidence; R3 reruns are reported separately. No merge or release has occurred. Hosted checks for this head are not run because Actions is paused.Executed results:
Full SQLite package suite: 428 passed, zero failed, 11 ignored, counting child-fixture result blocks. Ignored cases are the existing large pagination benchmark and ten documentation examples; no ignored PostgreSQL tests are counted as executed. Backend coexistence, federation end-to-end, cross-crate relationships, ordinary SDL and dependency-minimal repository fixtures executed successfully.
SQLite migration/schema/history/guards lane: 99 passed, zero ignored.
SQLite released timestamp, UI, projection, count and portable-group regression lane: 25 passed, zero ignored.
PostgreSQL migration/schema/history plus released timestamp/projection/count/group regression lane: 106 passed, zero ignored; actual disposable database execution, including system RLS and incoming FK preservation.
External repository consumer: SQLite 2 passed plus all examples compiled; PostgreSQL 2 executed timestamp/event-enumeration tests. It has no direct async-graphql dependency.
Legacy migration namespace external fixture: 1 passed on each SQLite/PostgreSQL/MSSQL feature lane (source/compile evidence, no database).
Macros: 9 unit tests passed per backend, six existing documentation examples ignored per lane.
MSSQL runtime migration capability: 1 passed, proves rejection before pool acquisition; no live MSSQL execution.
Canonical owned runners: SQLite 87 passed, PostgreSQL 69 passed, zero ignored in both. PostgreSQL includes the plain repository aggregate/field-denial external consumer.
Warnings-denied Clippy across all SQLite targets, plus scoped PostgreSQL/MSSQL Clippy and all three Rustdoc lanes: passed. Explicit SQLite/PostgreSQL/MSSQL/SQLite+MSSQL
cargo checkand dependency trees, plus workspace duplicate inspection: passed.Formatting, governed documentation (192 files), inventory, dependency architecture, package release policy, ordinary semver gate and release-state/manifest checks: passed. Manifest tests 6 passed, router notice checks 13 passed.
Strict source compatibility against released 0.39.0 with
--release-type patch: 223 passed, 30 inapplicable checks skipped, no source break. The external enum namespace fixture separately proves Rust variant/glob imports, matches, inferred values, literals and function pointers.Owned SQLite host example: compiled/executed, committed two statements, verified no-op replan and dependency certification.
Reproducible focused commands:
Additional verification commands (all passed):
Existing CI/release definitions now select the owned PostgreSQL migration suite, MSSQL pre-I/O rejection and legacy external imports for future authorized runs. YAML parsing and shell syntax checks passed. Both added commits contain
[skip ci]; the GitHub run listing for this exact head is empty. No workflow was dispatched or enabled.The new cross-slice test initially had fixture API/trait-bound compile errors, corrected before these successful runs. Its hash-equivalence fixture now explicitly declares the same
id ASCdefault-order spelling on both sides, as required by the existing metadata-sensitive hash contract; no production planner change was made. Existing MSSQL external host-timestamp example has an unused-import warning; it was compiled without a warnings-denied claim. Broader non-SQLite all-target gating in #89 is outside this change.Every build uses
CARGO_BUILD_JOBS=2, Rust 1.97.1, disk-backed scratch/targets, and sequential backend lanes. SQLite resources are test-owned; PostgreSQL fixtures own labelled loopback containers and verify immutable ownership before cleanup. Ambient application databases are not used. MSSQL evidence is compilation/rendering or pre-I/O capability rejection; live MSSQL execution was not run.Compatibility and limitations
No static API, ordinary GraphQL SDL, cursor format or host timestamp write/default behavior changes. Runtime conversion still has its documented representability limits; no implicit stored-data migration is introduced. Unrepresentable live FK semantics reject even no-op certification. Arbitrary external DDL requires a host fence/fresh environment; ORM fingerprints are separate from the host's complete public/policy revision. Existing static transaction cancellation remains unchanged: catching an inner mutation timeout then returning
Okdoes not guarantee rollback. B provides the stronger runtime operation/hook guard separately.Independent string predicate/binding work is in #112 (ORM/macros 0.39.1) and is not folded into A. These candidates both currently base released 0.39.0. If #112 merges first, reconcile A again with that reviewed commit and rerun affected combined checks before release; owner merge/release of #112 first is the requested order. Neither branch may move package versions backward or reuse a published source identity. B–D remain approved proposals with unimplemented interfaces, gated on exact committed, reviewed predecessors. No catalog, policy language, transport, SDK, durable replay, product/sibling changes, merge or release publication is implied. Broader PostgreSQL/MSSQL all-target gating remains tracked separately in #89.
Digibase handoff
After owner review/merge/release, pin the immutable release identity/full source revision with aligned ORM/macros and
default-features = false, selectingsqliteorpostgres. Validate the owned RuntimeSchema, compose trusted system entities, provide the host's persisted managed table set (including intentionally removed tables), plan/review, then explicitly apply with the source-hash and risk guards. Replan to no-op and establish the environment after verified application, under the host's external-DDL fence. Preserve host RLS and validate policy-only revisions separately before future B writes. Run downstream SQLite/PostgreSQL contracts before adoption. A alone does not enable runtime mutations or GraphQL registration. No release identity is assigned while owner gates and Actions pause remain in force.Documentation impact
Canonical runtime-migration reference, compiled example, active A–D checkpoint, changelog/migration notes, aligned README/manifests/locks and generated package inventory. Accepted ADRs are unchanged.