Repository navigation
Weasel 10.0.0-alpha.2
Pre-release
Pre-release
·
100 commits
to master
since this release
Second alpha of Weasel 10.0 for the Critter Stack .NET 11 release train. Targets net10.0 and net11.0. See the 10.0 migration guide.
Build: runtime-async on net11.0
- Every Weasel assembly's
net11.0build is now compiled with runtime-async, as in Wolverine 7.0 and JasperFx 3.0 (plan decision D4) (#816, #818).net10.0is unchanged. - Wolverine measured 38–84% fewer allocations with it on. Watch for differences in async stack traces, debugger stepping, and APM agents or profilers that hook async state machines.
- If you build from source, opt out with
-p:WeaselRuntimeAsync=false.
New seams for Marten, Polecat and Fisher (all additive)
- Async Hi-Lo (#808, #820)
ISequence/HiloSequenceBasegainNextLongAsync/NextIntAsync. They fetch an exhausted allocation through the existing asyncAdvanceToNextHi, and complete synchronously when the id is pure arithmetic.- Sync and async callers share one gate. That gate is now a non-re-entrant
SemaphoreSlim, so anAdvanceToNextHioverride must not call back intoNextLong.
- Master-table tenancy (#809, #821)
MasterTableTenancyBase.BuildDatabasesAsyncnow evicts tenants removed or disabled on another node, through aprotected virtual EvictStaleTenantAsynchook.MasterTenantStatus,LookupTenantAsync/ResolveTenantAsyncandCreateTenantRefusaltell a disabled tenant from an unknown one.⚠️ Fisher 2.0.0-alpha.1 needs an override to keep revoking tenants removed on another node (JasperFx/fisher#551).
- Batch executor (#810, #823)
OperationBatchExecutordrains the reader after the walk, so an error behind an unread result set now surfaces instead of being swallowed.- It also adds a surplus-result-set guard,
IStorageOperationWrappersoNoDataReturnedCallis still seen through adapters, and anIOperationBatchListenerfor per-command logging and exception transforms.
- Closed-shape storage (#811, #822)
- The tracking-mode bases are public.
IClosedShapeStorageRulesgains undelete, restore and mapped-version write-back.- New
ClosedShapeSubClassDocumentStoragefor hierarchies.
Performance
- Parameter-type lookups allocate nothing on a memo hit (#804, #824). The memo writes were capturing lambdas, which allocated a closure on every lookup.
- PostgreSQL also remembers an unmapped type against the mapping registry's version, so enum and array lookups drop from about 470 ns and 950 B to about 10 ns and 0 B.
- A mapping registered later still takes effect.
- SQL Server's reserved-word check is a hash lookup for printable-ASCII names (#825, #828). SQL Server DDL generation goes from about 85 µs to about 2 µs per table, with every answer unchanged (pinned against the old implementation).
- #805 (span formatting) was measured and closed as not applicable.
SQL Server
- Update and rollback scripts re-run cleanly (#814, by @jovball):
- column adds are guarded by
COL_LENGTH - primary key and check constraint adds by
OBJECT_ID - key-column
NOT NULLalters byCOLUMNPROPERTY - column, primary key and table type drops use
IF EXISTS
- column adds are guarded by
- Also from @jovball (#815):
- A column type change that involves a default no longer fails, and can run twice.
- The
CREATE TABLEguard usesN''and the'U'type. This changes the create text, soUseSchemaFingerprintingre-stamps once. - The JSON index guard keys on the column, not the table.
- Partition
SPLIT RANGE/MERGE RANGEare guarded.
Fixes and dependencies
db-patchanddb-dumpcreate a missing output directory (#813, by @jovball). The same fix shipped on the 9.x line as 9.50.2.Npgsql.NetTopologySuite10.0.3, matchingNpgsql10.0.3 (#819). The Npgsql 11 move (#812) waits for Npgsql 11 to ship.- The
Try*parameter-type lookups no longer throw for an unmapped generic, nullable or collection type on any provider (#826, #827). For example,SqlServerProvider.TryGetDbType(typeof(List<int>))now returns null. PostgreSQL no longer overflows the stack on a self-enumerating type such asJToken. - Firebird: a
CREATE OR ALTERthat loses a race with "BLOB not found" is now retried like any other lost race (#829).
Full Changelog: v10.0.0-alpha.1...10.0.0-alpha.2