AI & Machine Learning

Replacing Elasticsearch with ClickHouse : A 90% Cost-Reduction Migration

1m & 1 s read383 views0 listens

Platform Architecture Overview

This document outlines the transition from an Elasticsearch-based observability platform to a ClickHouse-based architecture for a crypto exchange application. The goal is to improve performance, reduce costs, and enable advanced analytics by leveraging ClickHouse's capabilities.

Target Architecture

The proposed architecture includes:

  • Crypto Exchange Apps: Applications such as Trading Service, Wallet Service, Risk Service, User Service, API Gateway, Background Workers.
  • OTEL SDK (OpenTelemetry): Auto-instruments various components like HTTP, DB, Kafka, Redis without requiring any changes to the application code.
  • OTEL Collector: Processes and exports data using ClickHouse exporter.
  • ClickHouse Cluster: Stores logs, traces, metrics, and business data in a single cluster for seamless integration.
  • Grafana: Provides dashboards, trace viewer, log explorer, and alerts.
  • LibreChat + LLM (Language Model): Enables AI queries over logs in plain English.

What Changes vs Current Stack

ComponentBeforeAfter
OTEL SDKSameSame — zero changes
OTEL CollectorSameSame — only exporter config changes
Storage

Read the full article at DEV Community


Want to create content about this topic? Use Nemati AI tools to generate articles, social posts, and more.

Views383
On this page
Ali Nemati
Ali NematiBlogUI.author_articles
BlogUI.view_profile