Repository navigation
docs(readme): show only APIs that exist in the source - #298
Merged
Merged
Conversation
Samples in the README called methods that BLite does not have, so copying them failed to compile, and nuget.org shows the same README for every package. Each corrected sample was compiled and run against src/. - Encryption: MigrateToEncryptedAsync, MigrateToPlaintextAsync, RotateEncryptionKeyAsync and KeyRotationOptions do not exist; say so instead of showing them, and drop the matching roadmap claim. - Secure erase: HasSecureErase does not exist and DocumentDbContext has no VacuumAsync. Describe what the code does: a delete zero-fills the bytes on its page, the file gets them at the next checkpoint, and VacuumAsync with VacuumOptions.SecureErase zero-fills all free space. - Sync calls removed in v4 or never present: FindById, Insert, engine.Commit, CreateIndex/CreateVectorIndex/CreateSpatialIndex on DynamicCollection, Scan, BLiteMigration.ToMultiFile/ToSingleFile. - BsonDocument has no GetString, GetDouble or Id; use GetValue(...).As*, TryGetString and TryGetId. BsonSpanReader has no TryReadString. - AppDb -> AppDbContext: the generator only handles a context whose name ends in "Context", and the encryption sample declares AppDbContext. - RFC.md and C-BSON.md links are absolute, since relative links break in the packed README on nuget.org. Refs EntglDb#296 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 17, 2026
Open
Collaborator
Author
|
The two findings listed under "Found while checking" are now issues:
Both are also listed in #296 section 8. |
This was referenced Oct 18, 2026
mrdevrobot
requested changes
Oct 18, 2026
mrdevrobot
left a comment
Contributor
There was a problem hiding this comment.
Changes requested. Every changed line checks out against the source. But the same Read block (README ~801–808) still shows orders.QueryIndex(...), VectorSearch(...), Near(...) and Within(...), which do not exist: DynamicCollection only has the *Async forms returning IAsyncEnumerable<BsonDocument>. Fix those four lines with await foreach and this can go in.
…*Async streams Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Collaborator
Author
|
Done in f38f1e0: the four lines now use |
mrdevrobot
approved these changes
Oct 20, 2026
This branch was successfully deployed
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.
Part of #296 (section 8, "wrong today"). Docs only,
README.mdonly.The README showed APIs that BLite does not have, so a sample copied from it did not compile, and nuget.org shows the same README for every package. Each corrected sample was compiled and run against
src/at 0450b97 in a scratch console app (not committed): 12 checks, all pass.collection.FindById(...)await collection.FindByIdAsync(...)new AppDb(...)new AppDbContext(...)Context(BLiteConventions.DbContextClassSuffix); the encryption sample declaresAppDbContextMigrateToEncryptedAsync,MigrateToPlaintextAsync,RotateEncryptionKeyAsync,KeyRotationOptionssrc/HasSecureErase(true),db.VacuumAsync()on a contextDocumentCollection.DeleteCore→CompactPage+Clear,DynamicCollection.DeleteSlot→SlottedPageUtils.CompactAndErase); the file gets the zeroed page at the next checkpoint;VacuumAsync(new VacuumOptions { SecureErase = true })on the engine or a collection, thenCheckpointAsyncHasSecureErasehas no match;DocumentDbContexthas noVacuumAsync. Checked at run time: a marker string is gone from the typed.dbafter delete and dispose; on aBLiteEngineit stays in.dbuntilCheckpointAsyncengine.Commit()await engine.CommitAsync()BLiteEnginehasCommitAsynconlyd.GetString("status")d.TryGetString("status", out var s) && s == "pending"BsonDocumenthas noGetStringorders.Scan(...)withreader.TryReadString(...)ScanAsyncwith the element loop the tests useScanonDynamicCollection, noTryReadStringonBsonSpanReaderCreateIndex,CreateVectorIndex,CreateSpatialIndex*AsyncformsDynamicCollectionhas async index creation onlyFindById,doc.GetString,doc.GetDouble,doc.IdFindByIdAsync,GetValue(...).AsString/AsDouble,TryGetId,TryGetStringBsonDocumentAPIcol.Insert(eventDoc)await col.InsertAsync(eventDoc, ct)BLiteMigration.ToMultiFile(/ToSingleFile(await ...ToMultiFileAsync(/ToSingleFileAsync(HasSecureErase(true);ToMultiFile()RFC.md,C-BSON.md(relative)Not changed here (separate items in #296): the README structure, the outdated version banners, the duplicated BLQL section, and RFC.md / C-BSON.md themselves.
Found while checking, not fixed here:
GdprStrictValidatorwarns at run time that "Deleted document slots are not currently zeroed at the page layer", but both delete paths zero them (checked at run time above). The warning, and its pointer toMISSING_FEATURES.md §3, look out of date.DocumentDbContextsubclass whose name does not end inContextgets no generated code and no diagnostic; its collection properties staynulland the first call throws aNullReferenceException.Line endings stay CRLF; the diff touches only the changed lines.
Conflicts with other open PRs
Conflicts with #310 (write-write conflict detection) in
README.md, in the roadmap list. Resolution: #310's BLiteSession line (the first committer wins) and this PR's migration line (ToMultiFileAsync/ToSingleFileAsync). Either PR can land first; I will push the resolution to the second.🤖 Generated with Claude Code