Refactor docs: topic folders, TOON, XCUT, protocol sync - Migrated all topic documentation into dedicated folders with canonical `README.md`, `ISSUES.md`, and `TODO.md` per topic (e.g., `LOGGING/`, `SIGNALR/`, `BINARY/`, `TOON/`). - Added comprehensive TOON serializer documentation: design, format, options, attributes, inference, issues, and TODOs. - Introduced `XCUT` folder for cross-cutting issues and TODOs, with canonical entries and topic cross-references. - Updated all references and navigation to use new folder-based doc paths; fixed links and clarified doc structure. - Enhanced AI agent protocol: enforce session skill preloading, `[LOADED_DOCS: ...]` short-name prefix, and mandatory `docs-check` skill for doc/code sync. - Updated `.csproj` to include all `README.md` files for IDE visibility. - Improved and clarified SignalR, grid, and project-level documentation. - Minor code/test tweaks and doc content corrections for consistency. |
||
|---|---|---|
| .. | ||
| AcLoggerSignalRHub.cs | ||
| AcSessionService.cs | ||
| AcSignalRDataSource.cs | ||
| AcSignalRSendToClientService.cs | ||
| AcSignalRServerProtocolExtensions.cs | ||
| AcWebSignalRHubBase.cs | ||
| ExtensionMethods.cs | ||
| IAcSessionItem.cs | ||
| IAcSignalRHubItemServer.cs | ||
| README.md | ||
| TrackingItemHelpers.cs | ||
README.md
SignalRs
Server-side SignalR hub infrastructure: hub base class, session management, data source with change tracking, and client broadcast service.
Architecture: For full dispatch flow, tag system, and tech debt documentation see
AyCode.Services/docs/SIGNALR/README.md.
Key Files
Hub
AcWebSignalRHubBase.cs— Abstract hub extendingHub<IAcSignalRHubItemServer>. Manages connection lifecycle, message dispatch viaDynamicMethodRegistry, binary/JSON parameter deserialization. Response methods:ResponseToCaller(),SendMessageToOthers(),SendMessageToUserIdInternal().IAcSignalRHubItemServer.cs— Server hub interfaces:IAcSignalRHubItemServer,IAcSignalRHubServer.AcLoggerSignalRHub.cs— Specialized hub for receiving log items via SignalR (AddLogItem()).
Session & Broadcast
AcSessionService.cs— Generic session manager withConcurrentDictionary<TSessionItemId, TSessionItem>.IAcSessionItem.cs— Session item interface withSessionIdproperty.AcSignalRSendToClientService.cs— Abstract broadcast service:SendMessageToClient(),SendMessageToAllClients(),SendMessageToConnection(),SendMessageToUser().
Data Source
Full specification:
AyCode.Services.Server/docs/SIGNALR/SIGNALR_DATASOURCE.md
AcSignalRDataSource.cs— Generic real-time collection (AcSignalRDataSource<TDataItem, TId, TIList>) implementingIList<T>with full CRUD and change tracking.- Change tracking:
TrackingItem<T, TId>wraps each modified item withTrackingState+OriginalValuefor rollback.ChangeTracking<T, TId>manages the tracking list. - Loading:
LoadDataSource()(sync),LoadDataSourceAsync()(async callback),LoadItem(id)(single). Binary path usesBinaryToMerge()forAcObservableCollection(batch UI update viaBeginUpdate/EndUpdate). - Saving:
SaveChanges()iterates tracked items, posts each via CRUD tag, rollbacks on failure.SaveItem()for individual saves. - Sync state:
IsSyncing(Interlocked counter) +OnSyncingStateChangedevent for UI loading indicators. - Locking:
object _syncRoot(sync ops) +SemaphoreSlim _asyncLock(async ops).GetEnumerator()returns safe copy. - Working reference list:
SetWorkingReferenceList()allows external list to become inner storage (zero-copy). - Context:
ContextIds(object[]) +FilterText(string) sent with GetAll requests for server-side filtering.
- Change tracking:
Utilities
ExtensionMethods.cs—InvokeMethod()— invokes methods and unwrapsTask/Task<T>/ValueTaskresults.TrackingItemHelpers.cs— Deep clone helpers:JsonClone<T>(),ReflectionClone<T>().