Download the PHP package kowada-gmbh/error-reporting-bundle without Composer

On this page you can find all versions of the php package kowada-gmbh/error-reporting-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package error-reporting-bundle

Kowada Error Reporting Bundle

CI PHP Symfony

Shared Symfony bundle that automatically e-mails logged errors to a configurable address.

The bundle is maintained here as a versioned Composer dependency and pulled into individual Symfony projects via composer update kowada-gmbh/error-reporting-bundle.

Installation

The package is public on Packagist (the source itself stays proprietary, only the distribution is public) and can be required as a regular dependency:

Features

All classes under Kowada\ErrorReportingBundle\ are automatically registered as services via autowiring/autoconfiguration (see config/services.yaml).

Errors that get logged (except HTTP client errors, i.e. any 4xx status) are automatically e-mailed to a configurable address.

If sending the e-mail itself fails (misconfiguration, mailer outage, unreachable Messenger transport), ErrorHandler catches that instead of letting the exception propagate: the original error is therefore never hidden (it still reaches the other Monolog handlers as usual, e.g. the log file), and the reporting failure is additionally recorded via PHP's error_log(). If an asynchronous Messenger worker ultimately fails to deliver an ErrorMessage (after exhausting retries), this is detected instead of dispatching another ErrorMessage about it — preventing a loop of error reports about failed error reports. Detection relies on the message class Messenger adds to its log context, so it also covers failures before the handler runs, like a mailer that can't be created from an invalid MAILER_DSN.

Configuration in the consuming project:

  1. Bundle configuration in config/packages/kowada_error_reporting.yaml:

    If receiver or sender_address is missing, the handler throws an UnrecoverableMessageHandlingException on every error. This does not abort the request/command — ErrorHandler catches it (see above) and writes a notice via error_log() instead. Needless to say, you can also use environment variables for configuration instead of baking the values into the app.

  2. Register the handler in config/packages/monolog.yaml — recommended in front of Monolog's own deduplication handler, so a recurring error (a cron loop, a broken high-traffic page) doesn't trigger a new e-mail on every single occurrence:

    kowada_error_mail_dedup is the handler actually active in the stack; MonologBundle recognizes kowada_error_mail as referenced by it and does not additionally register it on its own — so nothing needs to be configured twice here. time (in seconds) sets how long an identical error (same level + same message text) is suppressed after the first delivery; the first occurrence of an error is never delayed by this. If plain registration without deduplication is enough, the kowada_error_mail block alone suffices.

  3. Recommended: route ErrorMessage to an asynchronous Messenger transport so sending the e-mail doesn't block the request:

    Without routing, the e-mail is sent synchronously within the current request.

  4. A working symfony/mailer transport (MAILER_DSN) is assumed.

Development


All versions of error-reporting-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=8.3
monolog/monolog Version ^3.0
symfony/config Version ^7.4 || ^8.0
symfony/dependency-injection Version ^7.4 || ^8.0
symfony/http-kernel Version ^7.4 || ^8.0
symfony/mailer Version ^7.4 || ^8.0
symfony/messenger Version ^7.4 || ^8.0
symfony/monolog-bundle Version ^4.0
symfony/twig-bundle Version ^7.4 || ^8.0
symfony/yaml Version ^7.4 || ^8.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package kowada-gmbh/error-reporting-bundle contains the following files

Loading the files please wait ...