Giter Site home page Giter Site logo

antistressstore / laravel-log-enhancer Goto Github PK

View Code? Open in Web Editor NEW

This project forked from freshbitsweb/laravel-log-enhancer

0.0 0.0 0.0 38 KB

Make debugging easier by adding more data to your laravel logs (Laravel 5.6+)

License: MIT License

PHP 100.00%

laravel-log-enhancer's Introduction

Latest Stable Version Total Downloads License StyleCI Buy us a tree

Laravel Log Enhancer (Laravel 5.6 to Laravel 8.x)

Laravel's logging system helps a lot for storing data as well as while troubleshooting some hidden bugs. The data related to the exception automatically gets logged whenever something goes wrong.

Sometimes, we need more than just stack trace to debug the issue easily. The things like request URL, request input data, session data, etc. help us hunt down the exact cause quickly. That's what this plug-and-play Laravel package does for you :)

Requirements

PHP Laravel Package
7.3+ 8.x v1.3.0
7.2.5+ 7.x v1.2.0
<7.2.5 6.x v1.1.0
<7.1 5.x v1.0.*

Notes:

Installation

  1. Install the package by running this command in your terminal/cmd:
composer require freshbitsweb/laravel-log-enhancer
  1. Add this package's LogEnhancer class to the tap option of your log channel in config/logging.php:
'production_stack' => [
    'driver' => 'stack',
    'tap' => [Freshbitsweb\LaravelLogEnhancer\LogEnhancer::class],
    'channels' => ['daily', 'slack'],
],

Optionally, you can import config file by running this command in your terminal/cmd:

php artisan vendor:publish --tag=laravel-log-enhancer-config

It has following configuration settings:

  • (bool) log_request_details => Set to true if you wish to log request data. Reference

  • (bool) log_input_data => Set to true if you wish to log user input data

  • (bool) log_request_headers => Set to true if you wish to log request headers

  • (bool) log_session_data => Set to true if you wish to log session data

  • (bool) log_memory_usage => Set to true if you wish to log memory usage Reference

  • (bool) log_git_data => Set to true if you wish to log git branch and commit details Reference

  • (array) ignore_input_fields => If input data is being sent, you can specify the inputs from the user that should not be logged. for example, password,cc number, etc.

Lumen compatibility

We do not use Lumen in any of our projects. And this package is not tested with Lumen framework. If you are willing to use this package with Lumen, please help us by testing and making a PR to make it work. Thanks.

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE file for details

Treeware

You're free to use this package, but if it makes it to your production environment I would highly appreciate you buying the world a tree.

It’s now common knowledge that one of the best tools to tackle the climate crisis and keep our temperatures from rising above 1.5C is to plant trees. If you contribute to our forest you’ll be creating employment for local families and restoring wildlife habitats.

You can buy trees at for our forest here offset.earth/treeware

Read more about Treeware at treeware.earth

Special Thanks to

laravel-log-enhancer's People

Contributors

djallits avatar gauravmak avatar hirenkeraliya avatar mnastalski avatar repat avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.