Marten docs: fix stale IRevisioned int->long widening reverted by #4533#4534
Merged
Merged
Conversation
…ion for the #4533 revert An early 9.0 alpha widened IRevisioned.Version to long; #4533 reverted that before rc.1 (IRevisioned stays int, V8-compatible) and added ILongVersioned (long) for MultiStreamProjection documents whose Version is the global event sequence number. The migration guide still told users to widen Version to long. Rewrite the section to lead with the reversal, introduce ILongVersioned with the Int32-overflow rationale, and replace the widen-to-long example with a correct IRevisioned(int)/ILongVersioned(long) pair. Every Before|After type in the table was verified against origin/master source: IRevisioned.Version is int (unchanged); DocumentMetadata.CurrentRevision, UpdateRevision/TryUpdateRevision parameters, IRevisionedOperation.Revision and the m.Revision metadata column are long (and source-compatible via int->long). Dropped the stale claim that MapTo to an int property throws (RevisionColumn now accepts int or long). References updated to #4533 / #4526 / #4528 / #348; #3733 / #4377 are historical. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…nippet (int Version) The embedded sample_versioned_reservation snippet still showed long Version even though its source (src/Marten.Testing/Examples/RevisionedDocuments.cs) was already reverted to int by #4533. Regenerated via mdsnippets so the embed matches source. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
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.
Summary
An early Marten 9 alpha widened
IRevisioned.Versionfrominttolong(#3733 / #4377). PR #4533 reverted that before rc.1 —IRevisioned.Versionstaysint(Marten 8-compatible), and a newILongVersioned(long) was added forMultiStreamProjectiondocuments whoseVersionis the global event sequence number. Two docs never got the memo. This is a docs-only fix.Two fixes
docs/migration-guide.md— the "Numeric document revisions widened from int to long" section was entirely stale (it told users to widen everyIRevisioned.Versiontolong). Rewritten to:ILongVersionedwith theMultiStreamProjection/ global-event-sequence rationale and theInt32overflow warning.longexample with a correctIRevisioned(int, unchanged) /ILongVersioned(long) pair.Before | Aftertype in the table was verified against currentorigin/mastersource. OnlyIRevisioned.Versionreverted toint; the internal surfaces (DocumentMetadata.CurrentRevision,UpdateRevision/TryUpdateRevisionparameters,IRevisionedOperation.Revision, them.RevisionmetadataColumn<long>) stayedlongand are source-compatible viaint→long.m.Revision.MapTo(...)to anintproperty throws —RevisionColumnnow acceptsintorlong.docs/documents/concurrency.md— the embeddedsample_versioned_reservationsnippet still showedlong Versioneven though its sourceRevisionedDocuments.cswas alreadyint. Regenerated viamdsnippets(not hand-edited). Unrelated incidental snippet drift inhostbuilder.md/retries.mdwas reverted to keep this PR focused.Test plan
src/production changes.vitepress build docsrenders clean (build complete, no errors).grepfor residual "widen IRevisioned to long" guidance returns only the new, correct reversal/ILongVersionedcontent.Refs #4533, #4526, #4528, #348.
🤖 Generated with Claude Code