Skip to content

Virtufin Platform Specifications

This site contains the formal specifications for the Virtufin microservices platform — a real-time financial market data pipeline built on .NET 10.0, Dapr, and Kubernetes.

Architecture

graph TB
    subgraph External["External"]
        BINANCE["Binance"]
        ALPACA["Alpaca"]
        WS["WebSocket<br/>endpoints"]
    end

    subgraph Platform["Virtufin Platform"]
        subgraph Services["Core Services"]
            GW["API Gateway<br/>(virtufin-api)"]
            WM["WorkManager<br/>(worker-management)"]
        end

        subgraph Workers["Workers on the WorkManager Runtime"]
            FEED["WebSocketFeed workers<br/>(websocket-feed)<br/>one per connection"]
        end

        subgraph Infra["Infrastructure"]
            DAPR["Dapr Sidecars"]
            REDIS["Valkey / Redis"]
            K8S["Kubernetes"]
        end
    end

    subgraph Consumers["Consumers"]
        CSHARP["C# Client"]
        PYTHON["Python Client"]
        TS["TypeScript Client"]
    end

    GW -- "gRPC (h2c)" --> WM
    WM -- "lifecycle, lease,<br/>InvokeWorkerCommand" --> FEED
    FEED -- "frames (outbox)" --> GW
    WM --> DAPR
    GW --> DAPR
    DAPR --> REDIS
    FEED -- "WebSocket" --> BINANCE
    FEED -- "WebSocket" --> ALPACA
    BINANCE --> FEED
    ALPACA --> FEED
    CSHARP -- "gRPC / gRPC-Web" --> GW
    PYTHON -- "gRPC" --> GW
    TS -- "gRPC-Web" --> GW
    K8S --- Services

Dependency Map

graph TD
    CC["cross-cutting"]
    PT["pubsub-topics"]
    SC["scenarios"]
    CDT["core-data-types"]
    AG["api-gateway"]
    WM["worker-management"]
    WSF["websocket-feed"]
    SDK["multi-sdk"]
    BEH["behaviour"]
    TUI["terminal-ui"]
    DEP["deployment"]
    CICD["ci-cd-tooling"]

    CC --> AG
    CC --> WM
    CC --> DEP
    CC --> CICD
    PT --> SC
    AG --> SC
    AG --> SDK
    WM --> SDK
    AG --> TUI
    WM --> TUI
    WSF --> TUI
    WM --> WSF
    DEP --> AG
    DEP --> WM
    CICD --> SDK
    PT --> BEH
    SC --> BEH
    WM --> BEH

Specifications

# Specification Description
1 Cross-cutting Shared infrastructure, API-mediated pub/sub and state, observability, resilience, security, trust model
2 Pub/Sub Topics Naming library and fragments, topic taxonomy, market/scenario worlds, CloudEvents envelope, state keys
3 Scenarios Scenario registry triplets, named hypothetical worlds, lifecycle statuses
4 Behaviour Explicit-state processes for strategies, indicators and executors, and their translation into workers
5 Core Data Types EAV framework, Variant, FlatBuffers, reactive observables
6 API Gateway Dynamic gRPC discovery and invocation, distributed state, pub/sub streaming, publication fence
7 Worker Management Polyglot worker lifecycle on Runtime actors, event-driven processing, per-sidecar delivery, worker engines
8 WebSocket Feed One WebSocket connection per worker: login and subscriptions on every open, routing, reconnect, commands, status, attachments
9 Multi-SDK C#/Python/TypeScript client SDKs from proto contracts
10 Client Testing Cross-language client test parity: ID comments, naming conventions, generated/hand-written namespaces
11 Terminal UI Operator dashboard: worker/connection/event management, multi-context, live streaming, AI assistant
12 Deployment Helm chart, Dapr components, per-service versioning
13 CI/CD Tooling Doc generation, gRPC client publishing, reusable workflows

The naming reference renders every published naming fragment. Descriptive material that is not normative (the code-generation architecture and the event catalog) lives in openspec/reference/ in the spec repo and is not published here.