musement/monolog-fluentd-bundle
A Symfony bundle that connects Monolog to Fluentd, adding a configurable handler so PHP applications can forward structured logs to Fluentd for centralized collection, routing, and analysis.
Architecture fit
Bundle, Extension, service definitions) targeting the Symfony 2.x kernel. Laravel does not load Symfony bundles, so the package cannot be composer required and wired in as-is.fluent/fluent-logger-php that serializes Monolog records and forwards them to Fluentd over the forward protocol (msgpack/TCP). That logic is small enough to reimplement in a single Laravel-compatible Monolog handler.driver => monolog with a custom handler factory is the correct integration surface. The package's Symfony layer is dead weight.Integration feasibility
symfony/symfony ~2.x, monolog ~1.x, and a transitive dependency on fluent/fluent-logger-php. Modern Laravel (10/11) runs PHP 8.2+ and Monolog 3.x — Composer will refuse to resolve, and forcing it invites runtime breakage.Monolog\Handler\AbstractProcessingHandler, inject a Fluentd client, map the Monolog record to the Fluentd tag/record structure, and register it through a custom channel in config/logging.php.Technical risk
Key questions
forward protocol specifically, or would Fluentd's HTTP/TCP inputs suffice (which Monolog's built-in handlers could cover without new code)?Stack fit
config/logging.php with channel drivers and handler_with/via callbacks; a Symfony bundle's services.yml and Extension::load() never execute.Log::channel('fluentd') and custom Monolog handler factories cleanly. A first-party handler is idiomatic; the bundle is not.Migration path
composer.json. Vendor or fork only the handler source into app/Logging/ (or an internal package) with attribution.AbstractProcessingHandler, add fluent/fluent-logger-php (or a maintained fork) as a direct dependency, and pin compatible versions.fluentd channel in config/logging.php using driver => monolog and a via factory that constructs the handler from env-driven config (host, port, tag, level, bubble).Compatibility
write() array shape, getDefaultFormatter behavior, Logger::API).in_forward enabled, shared key/TLS expectations, tag routing, and msgpack version alignment.Log facade context handling (exception rendering, context/extra), since Monolog 3 normalizes these differently than 1.x.Sequencing
Maintenance
Support
Scaling
Failure modes
Ramp-up
forward protocol and buffering semantics, and Laravel's logging channel internals.How can I help you explore Laravel packages today?