Shardis.Query.EFCore 0.1.0-prerelease0075

Suggested Alternatives

Shardis.Query.EntityFrameworkCore

Additional Details

Shardis.Query.EFCore  has been renamed to Shardis.Query.EntityFrameworkCore to be consistent with Microsoft.EntityFrameworkCore.* and others

This is a prerelease version of Shardis.Query.EFCore.
dotnet add package Shardis.Query.EFCore --version 0.1.0-prerelease0075
                    
NuGet\Install-Package Shardis.Query.EFCore -Version 0.1.0-prerelease0075
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Shardis.Query.EFCore" Version="0.1.0-prerelease0075" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Shardis.Query.EFCore" Version="0.1.0-prerelease0075" />
                    
Directory.Packages.props
<PackageReference Include="Shardis.Query.EFCore" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Shardis.Query.EFCore --version 0.1.0-prerelease0075
                    
#r "nuget: Shardis.Query.EFCore, 0.1.0-prerelease0075"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Shardis.Query.EFCore@0.1.0-prerelease0075
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Shardis.Query.EFCore&version=0.1.0-prerelease0075&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Shardis.Query.EFCore&version=0.1.0-prerelease0075&prerelease
                    
Install as a Cake Tool

Shardis.Query.EFCore

Entity Framework Core query executor for the Shardis fluent query MVP (Where/Select, unordered streaming).

Features

  • Server-side translation of Where and final Select.
  • Unordered streaming merge across shards (arrival order, non-deterministic).
  • Automatic AsNoTracking() for all queries.
  • Optional per-shard command timeout.
  • Metrics via IQueryMetricsObserver (shard start/stop, items, completion, cancellation).

Usage

using Shardis.Query.Execution.EFCore;
using Shardis.Query;
using Microsoft.EntityFrameworkCore;

var exec = new EfCoreShardQueryExecutor(
  shardCount: 4,
  contextFactory: shardId => CreateDbContext(shardId),
  merge: (streams, ct) => Shardis.Query.Internals.UnorderedMerge.Merge(streams, ct),
  commandTimeoutSeconds: 15 // optional
);

var query = ShardQuery.For<Person>(exec)
                      .Where(p => p.Age >= 30)
                      .Select(p => new { p.Name, p.Age });

await foreach (var row in query)
{
    Console.WriteLine(row.Name);
}

Timeout: specify commandTimeoutSeconds in the executor constructor; unsupported providers silently ignore it.

Global ordering: wrap shard streams with the ordered merge helper instead of unordered merge (future API exposure).

Notes

  • Ordering across shards is not implemented in this executor; use ordered streaming merge utilities for global ordering.
  • Cancellation is cooperative; enumeration stops without throwing unless provider surfaces OperationCanceledException.
  • Ensure your DbContext factory is thread-safe and produces isolated contexts per shard query.
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.0-prerelease0075 307 8/28/2025 0.1.0-prerelease0075 is deprecated.