This repository was archived by the owner on Nov 21, 2026. It is now read-only.
Repository navigation
bindings docs: schema statements apply immediately; batch many in one transaction (#21) - #22
Merged
Merged
Conversation
…ctional; batch many in one transaction (#21) Upstream's answer on ArcadeData#8635. Adds tests/test_schema_batching.py. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WWcDr7TwvcfMsQkeYQVHZr
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Closes #21.
What changed
docs/api/schema.md: the "Auto-Transactional" note and best practice 1 (which marked wrapping in a transaction as unnecessary) now say what upstream confirmed on Schema changes cost 20 to 100 ms each on disk (10 to 40 times tmpfs): about 150 ms per type with one property and one index ArcadeData/arcadedb#8635: a schema statement takes effect at once and a rollback does not undo it, and many are batched in one transaction or onesqlscriptso the schema is written once.docs/guide/core/transactions.md: the section is renamed "Schema statements apply immediately", explains the batching and the crash behaviour Luca described, and gains a ten-type example.docs/api/transactions.md: the table row and thedb.command()paragraph say the same; the vector-index row keeps its "do not wrap" advice with the new wording.tests/test_schema_batching.py(2 tests) with its page, overview row, and nav entry.How it was verified
de966e79c5, before fix(#8635): write the schema once per DDL statement, never mid-transaction ArcadeData/arcadedb#8657): the behaviour they pin did not change with the fix.pre-commiton the changed files, bandit with CI's settings on the new test (no issues), andmkdocs build --strict(clean)..notes/bench/repros/ddl-cost/, published snapshot66a82a8fd0, Temurin 25 / 21, on disk): 30 types with a property and an index in one transaction cost 3.30 / 3.13 ms per type, against 44.86 / 44.16 before the fix; a standaloneCREATE DOCUMENT TYPEcosts 14.57 / 15.00 ms.🤖 Generated with Claude Code
https://claude.ai/code/session_01WWcDr7TwvcfMsQkeYQVHZr