Signals on the backend.
Basically support for GraphQL like queries string, to obtain computed properties exposed in a server (SSE, SignalR etc..)
SignalsDotnet.Query 3.1.2-alpha
SignalsQueryparses a brace-delimited selection set ({ title, sensors { name reading } }), withTryParsefor client-supplied input.SignalIsland<T>binds a model to a Synchronization Context with single-threaded semantics, so it needs no locks even while serving concurrent requests. Access it withInvokeAsyncorSwitchToIslandContextAsync.ReadComputedValuesAsyncstreams the projection as anIAsyncEnumerable, backed by a drop-oldest channel so a slow consumer receives the latest state instead of blocking the model.- A query also compiles to a plain selector via
ToQuerySelector<T>().
SignalsDotnet.AspNetCore 3.1.2-alpha
AddSingletonSignalIsland<T>(), plus scoped and transient variants, each with a factory overload. Constructor dependencies resolve throughActivatorUtilities.- Inject
SignalIsland<T>and stream it straight out of a minimal API withTypedResults.ServerSentEvents.
See the Queries section of the README for the four-step walkthrough, and the Playground projects for a running example with a client.