A step-by-step guide to sending structured .NET logs directly to ClickHouse using Serilog's ClickHouse sink. Covers configuring the sink with a fluent schema builder in C#, designing typed columns and JSON properties, enriching logs with correlation IDs, setting up full-text inverted indexes, and querying logs with SQL. Also addresses production concerns: batching parameters, TTL-based retention, MergeTree partitioning, failure handling callbacks, and real-time alerting via materialized views. A Docker Compose demo with a pre-built dashboard is provided.
Table of contents
Why ClickHouse for logs? #Setting up the infrastructure #Building the demo API #Running the demo #Exploring your logs #Production considerations #Resources #Conclusion #1 Comment
Sort: