Open Source · .NET

Stream processing, reimagined.

A modular SDK for building real-time data pipelines with built-in state management, change data capture, and stream processing — in idiomatic C#.

0K+
Events/sec
<0ms
Latency
0%
Open Source
Source
Kafka
Transform
.Map .Filter .Aggregate
Sink
Database
● running12,480 events/sec<10ms p99
Why Cortex
01

Stream processing, simplified.

A fluent API that reads like a sentence. Source → map → filter → aggregate → sink. Zero boilerplate, idiomatic C#, and the full expressive power of .NET.
State management
02

State, the way you need it.

In-memory for speed, persistent for durability. Plug in RocksDB, PostgreSQL, MongoDB, Cassandra, ClickHouse, SQL Server, or SQLite. Stateful aggregations and windowing work the same regardless of store.
CDC
03

Change data capture, built in.

Stream row-level changes from MongoDB, PostgreSQL, and MS SQL Server the moment they happen. No polling. No glue code. No lost events.
Production ready
04

Observable. Resilient. Scalable.

First-class OpenTelemetry integration, graceful error handling for poison messages, and horizontal workload distribution across instances. Built for real production systems.
Code Example

Build pipelines with a fluent API.

Create powerful streaming pipelines in just a few lines of expressive C# code.

Program.cs
var app = StreamBuilder
    .CreateNewStream("high-throughput-pipeline")
    .WithPerformanceOptions(options => {
        options.BufferCapacity = 10000;
        options.MaxConcurrency = 8;
    })
    .From(new KafkaSource("events-topic"))
    .Map(evt => Transform(evt))
    .Filter(evt => evt.IsValid)
.Aggregate(TimeWindow.Of(5), Count())
    .To(new DatabaseSink("analytics-db"))
    .Build();
Capabilities

Everything you need to build streaming applications.

Real-Time Data Streaming

Process millions of events per second with a fluent, type-safe API over Kafka, RabbitMQ, AWS SQS, and Azure Service Bus.

Multiple State Stores

In-memory and persistent: RocksDB, PostgreSQL, MongoDB, Cassandra, ClickHouse, SQL Server, SQLite.

Change Data Capture

Stream row-level changes from MongoDB, PostgreSQL, and MS SQL Server as they happen.

Windowing & Aggregations

Tumbling, sliding, and session windows with first-class aggregate operators.

Mediator Pattern

CQRS-ready mediator with commands, queries, notifications, and pluggable pipeline behaviors.

Telemetry & Monitoring

OpenTelemetry integration, graceful error handling, and production-grade observability out of the box.

Integrations

Works with the tools you already use.

Kafka
RabbitMQ
AWS SQS
Azure Service Bus
RocksDB
PostgreSQL
MongoDB
Cassandra
ClickHouse
SQL Server
SQLite
OpenTelemetry
Kafka
RabbitMQ
AWS SQS
Azure Service Bus
RocksDB
PostgreSQL
MongoDB
Cassandra
ClickHouse
SQL Server
SQLite
OpenTelemetry
Product Family

The Cortex ecosystem.

A modular set of packages designed to work together or independently.

Core

Cortex.Streams

High-performance real-time pipeline builder with a fluent API: map, filter, aggregate, window, fan-out.

Mediator

Cortex.Mediator

CQRS-ready mediator with commands, queries, notifications, and pluggable pipeline behaviors.

State

Cortex.States

Pluggable state stores: In-Memory, RocksDB, SQL Server, PostgreSQL, MongoDB, Cassandra, ClickHouse, SQLite.

Ready to build your next streaming application?

Get started with Cortex today and experience the power of modern .NET stream processing.