- What is php-monsters/laravel-xlog used for?
- It is a Laravel logging extension that aims to add additional data, including a track_id, to application logs. Based on the repository name and package description, it most likely provides a custom logging channel driver or Monolog wrapper rather than replacing Laravel's logging stack. The public description is thin, so confirm the exact output format and configuration in the README before relying on it.
- How do I install laravel-xlog?
- Install it with Composer using composer require php-monsters/laravel-xlog, then add or adjust a channel in config/logging.php according to the package README. Because the last release dates to August 2022, test installation in a disposable Laravel project first. Do not assume the package's service provider and config publishing steps are unchanged for modern Laravel versions.
- Does laravel-xlog support Laravel 10 and Laravel 11?
- There is no current support matrix in the provided context, and the package description's Laravel 5+ claim dates from an earlier era. With no release since August 2022, compatibility with Laravel 9, 10, or 11 and PHP 8.2+ is unverified. Treat it as outside its tested envelope until the maintainer confirms otherwise or you validate it yourself.
- How does laravel-xlog add track_id to logs?
- The package is described as adding additional data, including track_id, to Laravel logs. That usually means a Monolog processor, formatter, or custom channel driver injects the identifier into each log record's context. The exact mechanism and whether track_id is generated per request or supplied by the caller are not clear from the overview, so inspect the source or README.
- Is laravel-xlog compatible with Monolog 3?
- There is no evidence in the assessment that it has been tested against Monolog 3, which renamed or removed several handler APIs. The package's last release in August 2022 predates widespread Laravel 10/11 and Monolog 3 adoption. If your application uses Monolog 3, plan for a compatibility spike and expect possible handler or formatter breakage.
- Is laravel-xlog safe for production use?
- The TPM assessment does not recommend production adoption in its current state. Logging is a tier-zero observability dependency, and an unmaintained layer risks silent data loss during incidents. With zero dependents and no recent community scrutiny, you would be the first serious adopter and would absorb all discovery and security review costs.
- Can I add a track_id to Laravel logs without this package?
- Yes. Laravel and Monolog already provide first-class extension points: Log::withContext(), custom Monolog processors, custom channel drivers, and stack channels. A small middleware can generate a correlation ID and push it into the log context for each request. For most teams, that is less risk than adding a third-party package for the same result.
- How do I configure laravel-xlog in config/logging.php?
- You would typically add a channel entry with the driver class provided by the package and set it as the default or part of a stack. The exact driver name and options are package-specific and must come from the README or source code. Because the repository name differs from the Composer name, verify that the documented config keys match the installed version.
- Is laravel-xlog actively maintained and tested?
- The available signals point to low maintenance: 10 stars, zero dependents, last release August 2022, and a single small maintainer organization. There is no evidence of a changelog, CI pipeline, or test suite in the provided assessment. The repository name versus package name mismatch also complicates provenance review.
- What are the alternatives to laravel-xlog for extended logging?
- Native Laravel logging features cover most extended-logging needs: stack channels, custom Monolog processors, formatters, Log::withContext(), and custom channel drivers. For correlation IDs, a short middleware plus a Monolog processor is a common and well-understood pattern. Evaluate those before adopting an unmaintained package that adds a thin layer over the same primitives.