Agentic infrastructure with clickhousectl: a distributed ClickStack across three continents
A coding agent using the clickhousectl CLI stood up three ClickHouse Cloud services in us-east-1, eu-west-1 and ap-northeast-1, each ingesting OpenTelemetry logs, traces and metrics locally, with a federated global view in Europe for the ClickStack UI. The global view combines remoteSecure() table pointers to the remote regions with a Merge engine table over local and remote tables, so data stays resident in its region and is fetched only at query time. The agent scripted provisioning by parsing JSON output with jq and polling service status, then added SQL-based and native ClickStack alerts. The broader argument is that a scriptable CLI with clean JSON output suits agent-driven infrastructure better than a web console.
Related posts
- Open House observability announcements: MCP server, AI Notebooks, and ClickStack Cloud
ClickHouse easyNovice
ClickHouse unveiled three observability updates: ClickStack Cloud, a serverless managed OpenTelemetry endpoint now in private preview; general availability of Managed ClickStack for teams that want control over ingestion and sizing; and AI Notebooks in beta, which turn incident investigations into branching, editable, shareable workspaces. A new open-source ClickStack MCP server exposes intent-level observability tools such as log pattern trends, outlier attribute correlation and slow-trace inspection, along with dashboard and search management, so external agents need not generate raw SQL. In internal benchmarks against the generic ClickHouse MCP, these tools cut tool calls by 25%, raised consistency 2.5x and improved eval scores by about 20%, while raw SQL stays available as an escape hatch. A Docker all-in-one container and a Claude Code connection command make it easy to try locally.
- Agentic coding with ClickHouse. One person, one data stack, one full-stack application
ClickHouse easyNovice
A ClickHouse Solutions Architect with no frontend or backend background built ClickShop, a full-stack retail analytics demo, in a couple of days using Cursor. The stack uses Next.js on Vercel with per-persona workspaces, PostgreSQL for transactions synced to ClickHouse via ClickPipes CDC, and a Bronze/Silver/Gold medallion layout built on materialized views. On top sit 18 LibreChat agents, plus two observability layers: Langfuse for LLM tracing and cost, and ClickStack over OpenTelemetry for infrastructure. Open source components, Cursor skills and MCP database connectors reduce AI guesswork, though iteration, review and token costs remain significant.
- Building an Observability Solution with ClickHouse - Part 1 - Logs
ClickHouse mediumAdept
ClickHouse can serve as the storage backend for Kubernetes log collection using any of three agents: the OpenTelemetry Collector, Vector and Fluent Bit. Each agent can be deployed via Helm in agent (DaemonSet) and aggregator roles. Aggregators batch data into larger inserts that match ClickHouse insert best practices, and small deployments that skip them should use asynchronous inserts to avoid too many parts. The OTEL exporter (alpha) hard-codes its schema, while Vector (beta, HTTP/JSON sink) lets users define their own tables. Map types are recommended for sparse Kubernetes labels and annotations, and the post closes with compression results and example SQL queries for analyzing logs by pod, time window and string or regex match.
- Getting started with clickhousectl: the ClickHouse CLI for local and cloud
ClickHouse mediumAdept
clickhousectl (alias chctl) is a single CLI that manages local ClickHouse versions, isolated named servers, project scaffolding and ClickHouse Cloud services. Shared version binaries, per-directory named servers with auto-assigned ports, and a standard clickhouse/ layout for tables, materialized views, queries and seed data make side-by-side upgrade testing straightforward. Cloud auth is deliberately split: browser OAuth grants read-only access, while service creation, scaling and schema changes require an API key, a guard aimed at agent-driven use. The tool also installs Claude Code skills for local dev and cloud deploy, and fits into CI via a static binary, env-var auth and JSON output, with a sample GitHub Actions schema-validation workflow.
- Announcing the Managed ClickStack MCP Server
ClickHouse mediumAdept
ClickStack's MCP server, which exposes observability-specific investigation tools for logs, metrics and traces to agents like Claude Code, Cursor and Codex, is now available in Managed ClickStack on ClickHouse Cloud with OAuth and per-service dedicated compute. Semantic tools beat raw SQL generation: internal benchmarks show 25% fewer tool calls, 2.5x more consistency and roughly 20% higher eval scores than the generic ClickHouse MCP. The event patterns tool, for example, samples matching events, clusters them with Drain3 in the MCP layer and extrapolates counts, keeping query cost fixed instead of scanning the full dataset. The server also exposes orchestration tools so agents can persist investigations as dashboards and saved searches, while SQL remains available as an escape hatch.