PHPackages                             stseira/monolog-kafka - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Logging &amp; Monitoring](/categories/logging)
4. /
5. stseira/monolog-kafka

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

stseira/monolog-kafka
=====================

Apache Kafka handler for Monolog

v1.0.3(5y ago)0405MITPHPPHP &gt;=5.3.0

Since Dec 13Pushed 5y agoCompare

[ Source](https://github.com/stseira/monolog-kafka)[ Packagist](https://packagist.org/packages/stseira/monolog-kafka)[ Docs](http://github.com/kozlice/monolog-kafka)[ RSS](/packages/stseira-monolog-kafka/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependencies (2)Versions (5)Used By (0)

[Apache Kafka](https://kafka.apache.org/) handler for [Monolog](https://github.com/Seldaek/monolog)
===================================================================================================

[](#apache-kafka-handler-for-monolog)

[![Build Status](https://camo.githubusercontent.com/1187883d9b9b5d122d022361be70f2a0f16ea2149a060dd5f8856aff9d3fa36c/68747470733a2f2f7472617669732d63692e6f72672f6b6f7a6c6963652f6d6f6e6f6c6f672d6b61666b612e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/kozlice/monolog-kafka)

Support for logging into Apache Kafka using [rdkafka extension](https://github.com/arnaud-lb/php-rdkafka) (there are a few libraries for PHP, but this once seems to be most mature and supports Kafka versions 0.8, 0.9 &amp; 0.10).

Usage example:

```
$config = new \RdKafka\Conf();
$config->set('metadata.broker.list', '127.0.0.1');
$producer = new \RdKafka\Producer($config);
$logger = new Logger('my_logger');
$logger->pushHandler(new KafkaHandler($producer, 'test'));

```

Works with:

- PHP 5.6 &amp; [rdkafka 1.\*](https://pecl.php.net/package/rdkafka/1.0.0)
- PHP 7+ &amp; [rdkafka 2.\*](https://pecl.php.net/package/rdkafka/2.0.0) and [3.\*](https://pecl.php.net/package/rdkafka/3.0.0)

Manually tested with Apache Kafka 0.10.1.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 50% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~438 days

Total

4

Last Release

2121d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/63c5ab778b38de057e3bf0d393e25490ec965b269b4453383d2e46957fe1cf30?d=identicon)[YeongGwon Jeong](/maintainers/YeongGwon%20Jeong)

---

Top Contributors

[![stseira](https://avatars.githubusercontent.com/u/199357?v=4)](https://github.com/stseira "stseira (3 commits)")[![dzuelke](https://avatars.githubusercontent.com/u/27900?v=4)](https://github.com/dzuelke "dzuelke (2 commits)")[![kozlice](https://avatars.githubusercontent.com/u/747947?v=4)](https://github.com/kozlice "kozlice (1 commits)")

---

Tags

logpsr-3loggingkafkaapache kafka

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/stseira-monolog-kafka/health.svg)

```
[![Health](https://phpackages.com/badges/stseira-monolog-kafka/health.svg)](https://phpackages.com/packages/stseira-monolog-kafka)
```

###  Alternatives

[monolog/monolog

Sends your logs to files, sockets, inboxes, databases and various web services

21.4k964.9M7.0k](/packages/monolog-monolog)[analog/analog

Fast, flexible, easy PSR-3-compatible PHP logging package with dozens of handlers.

3451.5M24](/packages/analog-analog)[inpsyde/wonolog

Monolog-based logging package for WordPress.

183617.9k7](/packages/inpsyde-wonolog)[kozlice/monolog-kafka

Apache Kafka handler for Monolog

161.7k](/packages/kozlice-monolog-kafka)[apix/log

Minimalist, thin and fast PSR-3 compliant (multi-bucket) logger.

511.0M18](/packages/apix-log)[nvanheuverzwijn/monolog-logdna

Mezmo/Logdna handler for Monolog

21231.3k2](/packages/nvanheuverzwijn-monolog-logdna)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
