feat(grpc-data): H3 ProjectedHistoryAccess over deployed connections

Resolves, authorizes (HistoryRead demand: mapping bit + local grant on the
mapping scope, ACLs on or off) and pins each projected node, groups the batch
per connection / details / issuing endpoint and forwards through
IDataHistoryService. Remote cursors bind caller, mapping id+revision,
connection route, projection generation, origin view and serving identity, and
resend the ORIGINAL details; any change => BadContinuationPointInvalid with the
origin token released. Shared per-request assembly budget (min mapping
MaxHistoryAssemblyBytesPerRequest) => BadTooManyOperations for the remaining
nodes. Releases coalesce per connection. Replaces the H2 refusal pin with the
intended behaviour (granted => served, no grant => BadUserAccessDenied).
This commit is contained in:
Joseph Doherty
2026-11-24 00:28:17 -05:00
parent dc6cc7779d
commit 19b8163045
13 changed files with 949 additions and 29 deletions
@@ -122,6 +122,19 @@ public sealed class ProjectedMappingDeploymentRuntime : IDisposable
}
}
/// <summary>H3: the mapping's per-request history assembly budget, while its activated authority is current.</summary>
public bool TryGetHistoryAssemblyBudget(string mappingId, out long bytes)
{
bytes = 0;
if (!TryGetConnectionId(mappingId, out _)) return false;
lock (_gate)
{
if (!_byMapping.TryGetValue(mappingId, out var placement)) return false;
bytes = placement.Mapping.MaxHistoryAssemblyBytesPerRequest;
return bytes > 0;
}
}
public void Stage(CatalogAttempt attempt, IReadOnlyList<RemoteNamespaceMapping> mappings, IReadOnlyList<DataConnection> connections)
{
ArgumentNullException.ThrowIfNull(attempt);