up
Some checks failed
Signals CI & Image / signals-ci (push) Has been cancelled
Signals Reachability Scoring & Events / reachability-smoke (push) Has been cancelled
Signals Reachability Scoring & Events / sign-and-upload (push) Has been cancelled
Manifest Integrity / Validate Schema Integrity (push) Has been cancelled
Manifest Integrity / Validate Contract Documents (push) Has been cancelled
Manifest Integrity / Validate Pack Fixtures (push) Has been cancelled
Manifest Integrity / Audit SHA256SUMS Files (push) Has been cancelled
Manifest Integrity / Verify Merkle Roots (push) Has been cancelled
Docs CI / lint-and-preview (push) Has been cancelled

This commit is contained in:
StellaOps Bot
2025-12-12 09:35:37 +02:00
parent ce5ec9c158
commit efaf3cb789
238 changed files with 146274 additions and 5767 deletions

View File

@@ -155,7 +155,9 @@ public static class VexLensServiceCollectionExtensions
IServiceCollection services,
VexLensStorageOptions options)
{
switch (options.Driver.ToLowerInvariant())
var driver = (options.Driver ?? "memory").Trim();
switch (driver.ToLowerInvariant())
{
case "memory":
services.TryAddSingleton<IConsensusProjectionStore>(sp =>
@@ -165,19 +167,9 @@ public static class VexLensServiceCollectionExtensions
});
break;
case "mongo":
// MongoDB storage would be registered here
// For now, fall back to in-memory
services.TryAddSingleton<IConsensusProjectionStore>(sp =>
{
var emitter = sp.GetRequiredService<IConsensusEventEmitter>();
return new InMemoryConsensusProjectionStore(emitter);
});
break;
default:
throw new InvalidOperationException(
$"Unknown VexLens storage driver: {options.Driver}");
$"Unsupported VexLens storage driver: '{options.Driver}'. Supported drivers: memory.");
}
}
}