docs: a posts: unit of work covers the rows, not the number and the trail (#7297) - #7420
Merged
Merged
Conversation
…rail (#7297) `Posts.java.template`'s contract comment said a failed tick "leaves nothing behind". The unit of work covers the derived rows and their outbox events and nothing else: a target carrying `number:` allocates its document number before the insert and a `history: true` one writes its trail after it, each on its own connection, exactly as `JavaEntityStore.inUnitOfWork` documents - so a refused tick can consume a number and record the attempt. The comment now says "no rows". The same sentence is corrected for the scheduled tick in `intent-layer.md`, which additionally had no note for `posts:` / #7179 at all beside its #7132 and #7133 ones; `engine-intent/CLAUDE.md` gains the same pointer on its `postings:` bullet, so the next reader of the partial-UnitOfWork-adoption pattern finds that `Posts.java.template` is covered and what the unit does not reach. Fixes #7297 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
The defect
Posts.java.template's contract comment (and #7245's PR body) said a tick that fails part-way "leaves nothing behind". It leaves no rows - the unit of work covers the derived rows and their outbox events, and that is all it covers.JavaEntityStore.inUnitOfWork's own javadoc is explicit:So a
posts:target carryingnumber:orhistory: truedoes leave a consumed number and a trail entry of the attempt behind - by design, and identically toPosting(#7132), the scheduled tick (#7133) and the create-from (#7069).Second half:
.claude/docs/intent-layer.mddocumented #7132 and #7133 and had no sentence forposts:/ #7179 at all, andengine-intent/CLAUDE.mddid not change with #7245 either - so the next reader of the "partial UnitOfWork adoption" pattern would not find thatPosts.java.templateis covered.The change
Prose only, no behaviour.
Posts.java.template- "leaves no ROWS behind", plus what the unit does not cover and why (append-only records of an attempt, not business state)..claude/docs/intent-layer.md- the intent: a scheduled generation is not one transaction - and generate.unique: makes a partial tick permanent #7133 paragraph's identical overstatement corrected the same way, and aposts:/ postings: the per-item posting mode is not atomic and its back-reference guard makes a half-post permanent #7179 sentence beside the intent: the posting rewrite is not atomic - a failed item save leaves a partial journal entry #7132 one, stating once what a unit covers everywhere it is used.components/engine/engine-intent/CLAUDE.md- the same pointer on thepostings:bullet, namingPostIntent/Posts.java.template.Verification
Comment and Markdown only: no Java, no Velocity directive, no generated output changes. The added template lines are continuation lines of the existing block comment (
*), so nothing new is parsed by Velocity.Fixes #7297
🤖 Generated with Claude Code