RedBase Documentation

Welcome to the RedBase documentation portal. Browse the API reference, explore code examples, and learn how to build with REDB.

API Reference

Browse the REDB API documentation. Select a namespace or type from the tree on the left, or click on items below.

Showing: redb.Tsak.Core Show all

redb.Tsak.Core.Audit

Classes

C AuditHeaders Header names carrying a single audit event from the sink to the writer route.
C AuditQueryService Reads and prunes tsak_audit_log. Raw ADO.NET on purpose — the table is flat,
C AuditRetentionRouteBuilder Daily audit-log retention as a first-class redb.Route cron route (cron://tsak-audit-retention)
C AuditStorage The audit table and its statements. Everything provider-specific — connection string, ADO provider,
C TsakAuditRouteBuilder Audit writer: direct://tsak-audit → INSERT into tsak_audit_log.

Enums

E AuditProvider The three storage backends Tsak can be configured with, plus "none" for the

redb.Tsak.Core.Contracts

Classes

C ModuleActivationFailure A module that did not come up: its Initialize threw, or its context failed to start.
C TsakModuleRecord Module metadata stored in module store.

Interfaces

I IContextCustomizer Customizes a newly created RouteContext (add policies, services, etc.).
I IEmbeddedConfigModule A module that carries its per-module configuration ({Name}.config.json) embedded in the
I IHealthContributor Contributes additional health checks to .
I IStaticModuleProvider Provider of compile-time (static) modules registered via ProjectReference.
I ISystemContextPlugin Plugin for enriching the _system REST API context with additional controllers and services.
I ITsakClusterDirectory How many Tsak clusters share the database. Implemented by redb.Tsak.Core.Pro from the cluster
I ITsakContextManager Manages lifecycle of route contexts: create, start, stop, remove.
I ITsakCoordinator Orchestrates module-to-context mapping.
I ITsakLifecycleHook Generic lifecycle hook for Tsak startup/shutdown.
I ITsakModule Contract for a route module that can be discovered, loaded, and initialized in a context.
I ITsakModuleRegistry Registry managing discovery, registration, and lifecycle of route modules.
I ITsakModuleStore Persistent store for module metadata.
I ITsakSaveInterceptors Save interceptors a module subscribes for the life of its route context. The host keeps the redb ser...
I ITsakStateStore Persistent key-value state store for context and coordinator state.

Structs

S ModuleActivationReport What the coordinator could not bring up while activating modules in their contexts.

Enums

E TsakModuleStatus Status of a route module in its lifecycle.

redb.Tsak.Core.Controllers

Classes

C AuditController Query the persistent admin audit trail.
C AuthController API key management: create, list, revoke keys.
C ContextsController Context lifecycle management: list, start, stop, restart, remove.
C CreateKeyRequest
C DashboardController Aggregated dashboard snapshot endpoint for the web UI.
C DiagnosticsController Diagnostic endpoints: system dump and per-route diagnostics.
C ExchangesController Dead-letter queue: browse exchanges that failed at a route checkpoint, and replay or discard them.
C HealthProbeController Lightweight health probe endpoints for Kubernetes.
C LifecycleController REST API for the lifecycle event audit trail.
C LogsController Recent log access from in-memory ring buffer + log file management.
C ModulesController Module management: list, register, unregister modules.
C RoutesController Route-level management: list, detail, start, stop, inflight browse.
C SchedulerController Quartz scheduler management endpoints.
C StorageController Storage maintenance of the redb instances this node can reach.
C SystemController System-level endpoints: health, metrics, info.
C UsersController
C WatchdogController REST API for the Route Watchdog: status, alerts, enable/disable, alert-delivery test.

redb.Tsak.Core.Dlq

Classes

C CheckpointDlqHandler Context-level error handler (installed as RouteContext.ErrorHandler when Tsak starts the context) th...
C DlqRetentionRouteBuilder Daily dead-letter retention as a first-class redb.Route cron route (cron://tsak-dlq-retention)
C DlqService The dead-letter store and its operations: capture a failed exchange (from a route checkpoint),
C DlqStorage The dead-letter table and its statements. Lives on the same database and provider as the audit log
C ExchangeSnapshotCodec Serializes an snapshot for durable storage and rehydrates it back into a
C SerializedAttachment One stored message attachment of a .
C SerializedSnapshot Serialized form of an exchange snapshot for durable DLQ storage.
C TsakDlqComponent The checkpoint DLQ as an endpoint. Scheme: tsak-dlq; URI: tsak-dlq: (no path, no options).
C TsakDlqEndpoint The tsak-dlq: endpoint: a producer only.
C TsakDlqEndpointOptions Options of tsak-dlq: — none.
C TsakDlqProducer Dead-letters the failure the exchange carries, from its replay checkpoint.

redb.Tsak.Core.Extensions

Classes

C AdminAuditServiceCollectionExtensions DI helpers for registering Tsak admin audit components.
C AlertHttpClient Wrapper so a single long-lived can be a DI singleton.
C AlertServiceCollectionExtensions Registers the watchdog alert-delivery pipeline: the config-bound options, the natively
C ServiceCollectionExtensions DI registration for Tsak services.

redb.Tsak.Core.Models

Classes

C TsakContextInfo Context snapshot DTO built by ContextInfoCollector.CollectSnapshotsAsync.
C TsakEndpointSnapshot Endpoint snapshot in a shape the redb props store keeps, for heartbeat propagation.
C TsakRouteSnapshot Route snapshot in a shape the redb props store keeps, for heartbeat propagation.

redb.Tsak.Core.Modules

Classes

C LoadedAssemblyTracker Centralized registry of byte-loaded assemblies across all Tsak loading paths.
C ModuleAssemblyLoadContext Isolated for module isolation.
C ModuleContextMonitor Tells how many module load contexts are in memory and how many of them should be gone. A context sho...
C ModuleDeployResult Outcome of an upload or rollback attempt.
C ModuleLoadGate The ONE load-boundary trust gate for module code (review 2026-09-02, К3). Before this class the
C ModuleManifest Manifest embedded in a .tpkg package (manifest.json).
C ModulePackage Loads a .tpkg (ZIP archive) containing manifest.json + module DLLs + per-module config.
C ModuleSignatureOptions Signature-enforcement options, bound from Tsak:Modules:Signature. Governs the load
C ModuleSignatureVerifier Verifies a detached signature over a .tpkg package against a configured public key.
C ModuleUploadOptions Deployment security options, bound from Tsak:Modules.
C ModuleUploadService Handles remote module deployment: validates and installs an uploaded .tpkg, and rolls a
C RouteBuilderModule Adapter wrapping an IRouteBuilder implementation as an ITsakModule.
C SharedAssemblyLoader Loads assemblies from the shared layer (Libs/shared/) into the Default ALC.
C SharedRuntime Early, DI-free entry point to the shared assembly layer (Libs/shared).
C StaticMethodModule Adapter wrapping a static InitRoute.main method as an ITsakModule, in either form of the convention
C XmlRouteModule The third module convention (Route-XML Ф5.2): XML route artifacts from the package manifest,

Structs

S ModuleVersion Date-time based module version: yyyy.MM.dd.HHmm.

redb.Tsak.Core.Monitoring

Classes

C ContextMetricsCollector Collects per-context metrics from the context manager.
C ContextMetricsSnapshot A snapshot of a single route context's runtime state,
C ControlPlaneHealth Shared flag recording whether the _system control-plane context (REST/management API) started
C CpuMetrics
C DeployAdvisor Says whether a new package can be hot swapped into this node or the node needs a cold deploy (stop, ...
C GcMetrics
C HealthCheckService Evaluates overall system health based on context state and pluggable checks.
C HealthEvaluation Result of a health check evaluation (internal mutable model).
C LifecycleAuditService Ring-buffer audit trail for route lifecycle events.
C LogRingBuffer In-memory circular buffer for recent log entries.
C MemoryMetrics
C MemoryUsageEnricher Serilog enricher that adds current GC memory usage (KB) to every log event.
C MetricsCollectionService Background service that periodically collects process metrics
C MetricsOptions Configuration for the metrics collection subsystem.
C MetricsPoint A single snapshot of process and system metrics at a point in time.
C MetricsService In-memory metrics store with a circular buffer.
C NodeStartTime When this node started: the start time of its process, read once. GET /api/system/info (start time a...
C RingBufferSink Serilog sink that feeds structured log events into .
C RouteWatchdogService Background service that periodically scans all route contexts for
C ThreadingMetrics
C TsakMetricsSnapshotProps Props class of the per-node metrics snapshots stored in redb.
C WatchdogOptions Configuration for the Route Watchdog background service.

Interfaces

I IClusterDeployAdvisor The deploy advice of every alive node of the cluster (Pro). Without it the cluster form answers for ...
I IDeployAdviceContributor Adds the reasons for a cold deploy that only a plugin knows: Pro's cluster says whether this node is...

redb.Tsak.Core.Monitoring.Alerts

Classes

C AlertChannelResult Per-channel outcome of a test delivery.
C AlertDispatcher Fans watchdog / lifecycle alerts out to every enabled .
C AlertNotification A single alert to deliver. Produced from a WatchdogAlert (a newly detected hung /
C EmailAlertChannel Email delivery over SMTP using the BCL — no extra package. Adequate
C EmailChannelOptions Email via SMTP (BCL SmtpClient — no extra package).
C EndpointAlertChannel Generic route-endpoint channel: sends the alert JSON to any redb.Route producer URI
C EndpointChannelOptions Generic route endpoint — sends the alert to any redb.Route URI (kafka:topic,
C TelegramAlertChannel Telegram delivery via the Bot API — a formatted HTTPS POST to
C TelegramChannelOptions Telegram Bot API — a formatted HTTPS POST, no connector needed.
C WatchdogAlertOptions Alert delivery configuration, bound from Tsak:Watchdog:Alerts.
C WebhookAlertChannel Generic webhook: POSTs the alert JSON to a configured URL. Covers Slack / Teams / Mattermost /
C WebhookChannelOptions Generic outgoing webhook — POSTs the alert JSON to a URL (Slack/Teams/PagerDuty/…).

Interfaces

I IAlertChannel A single alert delivery destination (webhook, Telegram, email, broker endpoint).

redb.Tsak.Core.Pro.Cluster

Classes

C ClusterOptions Configuration options for cluster coordination.

redb.Tsak.Core.Pro.Cluster.Contracts

Classes

C LeaderSnapshot A consistent, point-in-time view of leadership. Read it (via )
C LockResult Result of a distributed lock acquisition attempt.

Interfaces

I IAssignmentManager Manages module-to-node assignments in the cluster.
I IClusterBootstrap Bootstraps the cluster tree structure: ClusterRoot → Group → Node.
I IClusterCoordinator Main cluster coordination service.
I IDistributedLock Distributed lock service using the redb object store with TTL-based expiry.
I ILeaderElection Distributed leader election via redb distributed locks.
I INodeRegistry Manages cluster node registration and heartbeat.

redb.Tsak.Core.Pro.Cluster.Models

Classes

C TsakAssignmentProps Redb props class for module-to-node assignment (live scheduling).
C TsakClusterRootProps Redb props class for the cluster root node in the tree hierarchy.
C TsakGroupProps Redb props class for a cluster group within the tree hierarchy.
C TsakLockProps Redb props class for distributed locks (leader election, etc.).
C TsakNodeProps Props of the redb scheme for cluster node registration and heartbeat tracking.

Enums

E AssignmentState State of a module assignment on a cluster node.

redb.Tsak.Core.Pro.Cluster.Policies

Classes

C ClusteredRoutePolicy Route policy that ensures only one node in the cluster runs the route consumer.
C ClusteredRoutePolicyFactory Factory that automatically creates for routes
C ClusteredRoutePolicyOptions Options for .

redb.Tsak.Core.Pro.Cluster.Services

Classes

C AlwaysLeaderElection Standalone fallback for : the current node is always the leader.
C ClusterCoordinator Main cluster coordination service.
C InProcessLock In-process implementation of intended for standalone hosting.
C NodeCordonState Process-local cordon flag for this node. A cordoned node keeps its current work running but
C RedbAssignmentManager Module assignment manager on redb storage ().
C RedbClusterBootstrap Bootstraps the cluster tree: ClusterRoot → Group.
C RedbClusterDirectory on redb storage: the clusters of the database are its cluster
C RedbDistributedLock Distributed lock on redb storage.
C RedbLeaderElection Leader election via the redb-backed distributed lock ().
C RedbNodeRegistry Node registry on redb storage ().
C RollingUpdateCoordinator Coordinates rolling updates across cluster nodes.

redb.Tsak.Core.Pro.Controllers

Classes

C ClusterController Cluster status and operations.

redb.Tsak.Core.Pro.Extensions

Classes

C DistributedLockExtensions Convenience extensions over .
C TsakClusterExtensions DI registration for the cluster subsystem (Pro).
C TsakInProcessFallbackExtensions Explicit opt-in registration for in-process fallback implementations of cluster primitives.

redb.Tsak.Core.Pro.Monitoring

Classes

C ClusterMetricsReporter Periodically writes a metrics snapshot to redb for cluster-wide aggregation.

redb.Tsak.Core.Security

Classes

C AdminAuditEvent Snapshot of a single audited admin operation.
C AdminAuditFilter Cross-cutting filter that emits an for every action
C ApiKeyProps Props class for API key entries stored as redb objects.
C ApiKeyRecord Represents a stored API key with associated metadata.
C ApiKeyService Validates API keys against .
C ApiResponse Unified API error/success response helpers for all Tsak controllers.
C AuditAdminActionAttribute Marks a controller action as an audited admin operation.
C AuthorizeProcessor Route pipeline processor that enforces API key authentication.
C ConfigApiKeyStore API key store backed by IConfiguration (appsettings).
C ConfigRedactor Redacts secrets from effective-configuration output (GET /api/system/config).
C FailedAttemptThrottle Per-key failed-attempt throttle (review item 4.5). After failures within
C LogAdminAuditService Fallback used when Tsak runs without a database
C NoRoleRequiredAttribute Marks an action (or a whole controller) as requiring no particular role — a valid API key
C RedbApiKeyStore Redb-backed API key store. Persists keys across restarts and cluster nodes.
C RequiresRoleAttribute Declares the role(s) required to invoke a controller action. Applied to a method it
C RoleAuthorizationProcessor Enforces on controller actions.
C RouteAdminAuditService Persistent admin audit sink: hands each event to the direct://tsak-audit route,
C TsakRoles Well-known Tsak roles, ordered by privilege: <

Interfaces

I IAdminAuditService SPI for delivering admin audit events to a sink. The effective implementation is
I IApiKeyStore Persistent store for API keys. Implementations: config-based, redb-backed, etc.

redb.Tsak.Core.Services

Classes

C ContextInfoCollector Collects rich context/route/endpoint info from live RouteContext instances.
C DiagnosticService Collects a comprehensive diagnostic snapshot of the system state.
C HotReloadOptions Configuration for hot reload. Bound to Tsak:HotReload.
C HotReloadService Manages hot reload of module assemblies.
C SystemContextBuilder Builds and starts the _system route context that hosts the REST management API.
C TsakContextManager Manages lifecycle of route contexts. Supports named (config-driven) and anonymous (dynamic) contexts...
C TsakCoordinator Orchestrates module-to-context mapping. Subscribes to registry events and
C TsakHostedService Main hosted service managing the Tsak runtime lifecycle.
C TsakModuleRegistry Thread-safe module registry with assembly scanning, batch events, and version tracking.
C TsakNodeIdentity The identity of this worker node: Tsak:Cluster:NodeId, or the host name when it is not set. One rule...

redb.Tsak.Core.Services.Storage

Classes

C InMemoryTsakModuleStore In-memory module store for Standalone mode. Not persistent across restarts.
C InMemoryTsakStateStore In-memory state store for Standalone mode. Not persistent across restarts.
C RedbTsakModuleStore Redb-backed module store. Persists module metadata across restarts and cluster nodes.
C RedbTsakStateStore Redb-backed state store. Persists key-value state across restarts.
C TsakModuleProps Props class for module store entries.
C TsakStateProps Props class for state store entries. Scheme is auto-created from type name.
C TsakUniqueBackfill One-time V4 migration pass: stamps ValueUnique onto rows written by pre-key

redb.Tsak.Core.Services.Storage.TsakUniqueBackfill