KafkaIQ

10.9.2 – When to Use REST vs Native Clients

Module: Section 10 – Kafka Ecosystem & Tools
Section: 10.9 – Kafka REST Proxy
Goal: Choose between REST Proxy and native clients


Decision Matrix

Scenario Recommendation
Python/Node.js app Native client (confluent-kafka-python, kafkajs)
Browser app REST Proxy (CORS support)
Quick prototype REST Proxy
Production pipeline Native client
Firewall restrictions REST Proxy
High throughput Native client

REST Proxy Limitations

  1. No consumer groups: Each request creates new consumer
  2. No exactly-once: At-least-once only
  3. No transactions: No multi-message atomicity
  4. Higher latency: HTTP overhead

Key Takeaways

  1. Prototyping: REST Proxy is great
  2. Production: Native clients preferred
  3. Browsers: REST Proxy only option
  4. Performance: Native clients 10x faster

What's Next?

Next Module: 10.9.3 – Producing Messages via REST