Sitemap

Designing a Centralized Logging System for Modern Systems

2 min readMar 3, 2026

--

In today’s complex microservice architectures, applications run across multiple distributed nodes, each generating logs independently. Without a centralized logging system, troubleshooting issues or monitoring performance becomes extremely difficult.

A well-designed logging system should make it easy to:

  • Troubleshoot and debug issues quickly
  • Monitor application performance in real time

In another words it should reduce Mean Time to Recovery (MTTR)

Beyond operational monitoring, applications also generate business-critical logs such as customer login, logout, transactions, and other activity events. These logs should be stored reliably and surfaced in the UI with minimal delay.

Modern Design for a Logging System

Whenever we design any system, we should be mindful of these things —

  • System should be scalable
  • Highly available
  • Less latency

A modern centralized logging system typically consists of the following components:

1. Log collectors (Agents)
Log collectors are lightweight agents deployed alongside application services. Their responsibility is to collect logs and forward them to a downstream system.

Common log collectors include Fluentd, Logstash, Filebeat etc..

Get Sajan K’s stories in your inbox

Join Medium for free to get updates from this writer.

However, directly sending logs from agents to storage (like S3 or a database) introduces a risk: If the agent or storage system becomes unavailable, logs can be lost. Also this is not viable in case we have real time stream coming in.

To solve this, we introduce a decoupling layer

2. PUB/SUB Layer
Most widely used PUB/SUB system is kafka. In kafka the producers(log collectors) gets the logs from the servers and produce it to kafka topic. And the consumers consumes this data from topic which it is subscribed to and forwards it to the storage system.
Kafka is suitable for High throughput and real time streaming systems.

3. Storage Layer
Choose a storage system that is reliable, distributed and durable. We should ensure that no data is lost. Common choices include blob storages such as s3, elasticsearch, druid etc..

It is not enough that data is in cloud blob storage. We should be able to query/search them seamlessly. For that we can use distributed solutions such as elasticsearch, druid etc.

4. Visulization System
Another major component in logging system is visulaization system which is an interface where we can actually query/monitor the logs. Some examples are kibana, grafana, grafana loki etc.

Press enter or click to view image in full size

Conclusion

As application architectures become increasingly distributed and complex, centralized logging is essential.

A reliable and scalable logging system:

  • Improves observability
  • Reduces downtime
  • Enhances debugging efficiency
  • Supports business analytics use cases

By combining log collectors, a streaming backbone like Kafka, distributed storage, and powerful visualization tools, we can build a robust logging infrastructure that scales with modern systems.

--

--