Home / Companies / Upstash / Blog / Post Details
Content Deep Dive

Export Kubernetes Pod Logs to Upstash Kafka via FluentBit

Blog post from Upstash

Post Details
Company
Date Published
Author
Enes Ozcan
Word Count
1,669
Language
English
Hacker News Points
-
Summary

FluentBit, a lightweight log processor and exporter, integrates with Upstash Kafka, a serverless and fully managed Kafka service, to streamline log management and processing for Kubernetes pods. By using FluentBit's Kafka output plugin, developers can export logs from Kubernetes pods specifically in the "upstashed" namespace to an Upstash Kafka cluster, which operates on a pay-per-message model and offers the first 10,000 messages free of charge daily. The setup involves creating an Upstash Kafka cluster and topic, deploying FluentBit to Kubernetes, and configuring it to filter and export logs. These logs are then consumed and streamed to clients via a Go-based HTTP server, allowing real-time access to selected log data without exposing sensitive information. This approach not only simplifies log management by eliminating the need for cluster maintenance but also enhances accessibility by streaming logs to HTTP clients who do not have direct access to Kubernetes or Kafka. Additionally, the buffered logs in Upstash Kafka can be further utilized by other backend systems, facilitating improved observability and diagnostics.