Harness the power of Kafka in your Laravel projects

Use Kafka Producers and Consumers in your laravel app with ease!

MyKafkaConsumer.php
composer.json
$consumer = Kafka::consumer(["my-topic"])
    ->withBrokers("localhost:8092")
    ->withAutoCommit()
    ->withHandler(new MessageHandler)
    ->build();
    
$consumer->consume();

Introduction

Do you use Kafka in your laravel projects? All packages I've seen until today, including some built by myself, does not provide a nice syntax usage syntax or, when it does, the test process with these packages are very painful.

This package provides a nice way of producing and consuming kafka messages in your Laravel projects.

Latest version on packagist Total downloads License Continuous integration Check fix & Styling PHP Version
Previous
Example docker-compose file