A high-performance system for efficiently reading YouTube Live Chat messages.
- Real-time Processing: Reading YouTube Live Chat messages with the most efficient method, streamList
- Scalable & High Available: Horizontally scalable reading workers; if one fails, another one takes over immediately
- Observable: Comprehensive metrics, tracing, and logging
- Kubernetes-Native: Designed to run in containerized environments
The system consists of two main components:
- Periodically checks configured YouTube channels for upcoming live streams
- Emits events when new live streams are discovered
- Runs as a Kubernetes CronJob for scheduled execution
A multi-binary service with the following components:
- Listens for newly discovered live stream events
- Creates the initial live stream progress state
- Runs as a Kubernetes Deployment
- Reads and stores live chat messages using YouTube’s streamList
- Distributed locking with Redis to ensure exactly-once live stream processing
- Runs as a Kubernetes Deployment
- Kubernetes cluster (e.g., Docker Desktop)
- Helm 3+
- kubectl
-
Clone the repository:
git clone https://github.com/natsoman/youtube-chat-reader.git cd youtube-chat-reader -
Deploy to your Kubernetes cluster:
# Navigate to the deployment directory and follow instructions cd deploy/local/k8s/
Configuration is managed through Kubernetes resources: