Visão Geral
O curso Producer Performance Tuning for Apache Kafka foi desenvolvido para profissionais que desejam dominar as técnicas de ajuste fino e otimização de desempenho dos produtores Kafka, garantindo maior eficiência, throughput e confiabilidade na publicação de mensagens em sistemas distribuídos.
Durante o curso, os participantes aprenderão a configurar e calibrar parâmetros críticos do Kafka Producer API, como acks, batch size, linger.ms, compression, retries e buffer.memory, bem como a realizar testes de carga, análises de métricas e identificação de gargalos.
Além disso, o treinamento inclui práticas avançadas para monitoramento e diagnóstico de desempenho em ambientes on-premise e cloud-native, integrando Prometheus, Grafana e Kafka CLI tools.
Conteúdo Programatico
Module 1: Kafka Producer Architecture and Workflow
- Overview of Kafka Producer internals
- Message serialization and delivery guarantees
- Batching, buffering, and message dispatch
- Understanding partitions and producer parallelism
- The role of acknowledgments (acks) and retries
Module 2: Key Producer Performance Parameters
- Configuring
acks, retries, and max.in.flight.requests.per.connection
- Optimizing
batch.size, linger.ms, and buffer.memory
- Compression types: gzip, snappy, lz4, zstd – trade-offs and impact
- Tuning for latency vs throughput scenarios
- Producer metrics overview: throughput, latency, record size
Module 3: Compression and Serialization Optimization
- Impact of message size and schema design
- Using Schema Registry with Avro and Protobuf
- Comparing serialization formats: JSON vs Avro vs Protobuf
- Optimizing compression for CPU vs network efficiency
- End-to-end compression benchmarking
Module 4: Load Testing and Benchmarking
- Using Kafka-producer-perf-test tool
- Setting up synthetic workloads for performance validation
- Analyzing producer latency and throughput metrics
- Simulating message backpressure and network saturation
- Real-world benchmarking case studies
Module 5: Monitoring and Observability
- Collecting producer metrics with JMX and Prometheus
- Visualizing latency and throughput with Grafana dashboards
- Alerting on dropped or delayed messages
- Correlating producer metrics with broker performance
- Troubleshooting common performance bottlenecks
Module 6: Advanced Tuning and Scaling Strategies
- Parallel producers and asynchronous publishing
- Optimizing client-side memory management
- Network-level tuning (TCP, socket buffers, DNS latency)
- Multi-threaded and multi-instance producer design
- Scaling Kafka producers in Kubernetes and cloud environments
Module 7: Real-World Scenarios and Best Practices
- Tuning for high-frequency event streaming
- Performance optimization in microservices environments
- Ensuring consistency and durability under heavy load
- Balancing cost, performance, and reliability
- Continuous performance testing in CI/CD pipelines
Module 8: Hands-On Labs
- Deploying and tuning producers in Docker-based Kafka cluster
- Running producer benchmark tests with different configurations
- Monitoring metrics with Prometheus and Grafana
- Identifying and fixing a real-world performance bottleneck
- Final performance tuning challenge