Download the PHP package johnturingan/laravel-exception-logger without Composer

On this page you can find all versions of the php package johnturingan/laravel-exception-logger. 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 laravel-exception-logger

Laravel Exception Logger

Its an Exception Logging Library made for Laravel Application

Installation

Run the following command

or modify your composer.json like below

Then run $ composer install or $ composer update, whichever you prefer.

Laravel Installation

You need to register the package by going to config/app.php file then add it to the list of providers.

or in Lumen Application

Then publish it by using this command

Keep in mind that config may vary from application to application, it is a must that you check your config file config/logging.php and replace the values that is suitable to the application who will use it.

Recommended Usage

Exceptions

There are several ways on how to use this package but it is highly recommended that you follow implementations enumerated below:

  1. It is highly recommend that you extend your custom exception from

    Snp\Logger\Exceptions\Exception

    Then set corresponding values info it like domain, reference_id, etc..

    If you extend your exception from Snp\Logger\Exceptions\Exception class, it will automatically log it in Graylog or in storage logs if configured in config/logging.php

  2. Another option is to use it in App\Exceptions\Handler file. Here's how to do it:

    • Extend the App\Exceptions\Handler class from Snp\Logger\Exceptions\Exception
    • In report() method, add "app_fault" property in Exception $e to determine which application throws an Error.
    • Then create an Snp\Logger\Info object and assign it to "log_info" property in Exception $e then pass the Exception to report() method.

      Below is an example:

      Using this option, you can manage all exception easily because its in single place only.

LOG SAMPLE OUTPUT

If all the properties has been filled up accordingly, below is the expected log output inside storate/logs/laravel.log


All versions of laravel-exception-logger with dependencies

PHP Build Version
Package Version
Requires php Version >=7.0
graylog2/gelf-php Version 1.5.*
jenssegers/agent Version 2.6.*
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 johnturingan/laravel-exception-logger contains the following files

Loading the files please wait ....