Skip to content

DotRocks 1.3.1

Choose a tag to compare

@kidoz kidoz released this 05 Jul 22:38
· 143 commits to main since this release

A patch release of DotRocks — a native .NET driver, Entity Framework Core provider, and Roslyn analyzer suite built specifically for StarRocks. It implements its own managed StarRocks client protocol and takes no runtime dependency on any MySQL driver. This release consolidates the EF Core table-shape handling behind a single shared annotation registry, fixes migrations that silently dropped StarRocks-specific table options, tightens model validation, and lands a broad internal consolidation of the driver and protocol test infrastructure with no change to observable behavior.

Added

  • Canonical table-shape fluent names HasStarRocksRandomDistribution(buckets) and HasStarRocksSortKey(columns), so every StarRocks table option shares the HasStarRocks prefix. DistributedRandomly and HasSortKey remain as forwarding equivalents, and the design-time scaffolder now emits the canonical names.
  • DotRocksJson values can now be bound as command parameters on both the text protocol (escaped string literal) and the binary prepared protocol; previously both paths threw NotSupportedException.

Changed

  • Table-shape annotations (key model, distribution, sort key, buckets, replication, properties) are now driven by one internal registry shared by the relational annotation provider, the model validator, the migrations SQL generator, and the design-time code generator, with a completeness test so a new option cannot be wired partially.
  • Model validation reports invalid table-shape configuration earlier and more precisely: sort-key columns must map to store columns, wrong-typed annotation values are rejected at model finalization instead of during SQL generation, and shared-table conflict checks now cover random distribution, sort keys, and table properties.
  • Extensive internal consolidation with no behavior change: the driver's four command paths share one packet-exchange and exception-translation helper, text and binary result-set parsing share one reader, the parameter-binder lexer twins are unified, and the protocol test suites share one fake server and packet factory.

Fixed

  • Migrations generated by the model differ no longer silently drop DISTRIBUTED BY RANDOM, ORDER BY sort keys, and custom PROPERTIES: the relational annotation provider now forwards those annotations into diffed CreateTableOperations.
  • Equivalent table PROPERTIES dictionaries on entities sharing a table no longer report a false conflict (comparison is now by content, not reference).
  • ObjectDisposedException during statement prepare or prepared execution is wrapped as a transient DotRocksException like every other command path instead of escaping raw.
  • Integration readiness probes (local just starrocks-up and CI) now verify a backend accepts CREATE TABLE before tests start; previously suites could launch while only the StarRocks frontend was up and fail spuriously.

Compatibility

  • .NET 10 / C# 14. Source-compatible with 1.3.0. The only public API additions are the HasStarRocksRandomDistribution / HasStarRocksSortKey fluent names (the prior DistributedRandomly / HasSortKey names still work) and DotRocksJson parameter binding. Existing valid code is otherwise unaffected beyond the bug fixes above; migrations regenerated against this version now correctly retain random distribution, sort keys, and custom PROPERTIES.

Full Changelog: v1.3.0...v1.3.1