TKey and an interface for key bytes and namespaces#1605
Merged
Conversation
c5d09b5 to
6f4e7c9
Compare
33b6cee to
a0a8ec8
Compare
In .NET 9+ IKey may be a ref struct. IKeyComparer is now generic (on methods). LogRecord and friends implement IKey. ISourceLogRecord implements TKey.
Most are even passing. ObjectIterationPushLockTest is flaky, but that is also true on tedhar/size-tracker . Same thing with RevivificationSpanByteTests, fail in this branch but crash or flake in tedhar/size-tracker . fix up more tests, restorign that weird input special casing
…for Vector Set keys, but does not introduce them
a0a8ec8 to
9c0f1a8
Compare
badrishc
approved these changes
Mar 6, 2026
badrishc
pushed a commit
that referenced
this pull request
Mar 10, 2026
* MInor cleanup
* Convert LogSizeTracker to be more fully LogRecord-ized
More Comments in BufferAndLoad
Fix RandomReadCacheTest input failure
* WIP changing to {MemorySize, PageSize, PageCount} where MemorySize includes Heap
* WIP: SizeTracker conversion
* WIP SizeTracker
* WIP on sizeTracker
* WIP SizeTracker
* WIP SizeTracker
* WIP SizeTracker - most tests pass
* WIP sizeTracker
* Tsavorite fixes for ReadOnlyAddress calculation, Recovery, some fixes for tests; make some ReadAtAddrss and Reviv tests [Explicit] temporarily. A couple Garnet test fixes for required minimum page count
* Fix StoreWrapper.RecoverCheckpoint() to ensure SizeTrackers are started
Fix MultiDBManager not propagating SizeTracker start when adding a DB
Fix SortedSetOps using wrong context
Fix Recovery not propagating LastPageFreed
Remove SizeTracker fields that duplicated LogSizeTracker
Fix Recovery eviction-range calculations
Disable some tests temporarily until they can be converted
* format
* Finish AsyncFlushPagesForReadOnly. Still a little WIP for AsyncFlushPagesForSnapshot
* Finish size tracker.
Fix some issues (resulting from going to GC.AllocateArray) with reusing allocator pages.
Replace the last NativeMemory allocations in Allocator with GC.AllocateArray.
* Make a couple tests [Explicit] temporarily
Move FreePage() up to just below Alloc/ReturnPage() so they're together
* Move to OPMROWorker; more fixes in Recovery
* format
* Re-enable some tests, and disable a couple others temporarily. Make sure OA page header is set correctly for object log position.
* TKey and an interface for key bytes and namespaces (#1605)
* Rework Tsavorite so TKey is a parameter again, constained by IKey.
In .NET 9+ IKey may be a ref struct.
IKeyComparer is now generic (on methods).
LogRecord and friends implement IKey.
ISourceLogRecord implements TKey.
* Get Tsavorite tests compiling.
Most are even passing.
ObjectIterationPushLockTest is flaky, but that is also true on tedhar/size-tracker .
Same thing with RevivificationSpanByteTests, fail in this branch but crash or flake in tedhar/size-tracker .
fix up more tests, restorign that weird input special casing
* benchmarks compile; no attempt to actually run them, converting Garnet first
* update Garnet to use new interfaces; everything compiles, nothing is tested
* formatting
* add namespace bits to Tsavorite
* populate namespace in log records
* all Tsavorite tests passing again
* punch namespace setting and new comparer into Garnet; this has TODOs for Vector Set keys, but does not introduce them
* Fix OA page clearing, Recovery EvictionPageRange, async test keys
* format
* Turn off "disposed" check on GetPhysicalAddress (due to Cluster.test Dispose sequencing)
---------
Co-authored-by: kevin-montrose <kmontrose@microsoft.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 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.
Take 3 on TKey additions for Namespace against store v2.
tedhar/size-tracker