2017 © Pedro Peláez
 

library laravel-segmentedsyslog

A Laravel Syslog Handler to handle maximum message lengths enforced by certain syslog implementations.

image

camuthig/laravel-segmentedsyslog

A Laravel Syslog Handler to handle maximum message lengths enforced by certain syslog implementations.

  • Friday, October 23, 2015
  • by camuthig
  • Repository
  • 1 Watchers
  • 1 Stars
  • 9 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

Laravel Segmented Syslog

Laravel Segmented Syslog provides an extension on the normal Laravel syslog service to enable breaking up log messages into chunks to fit into the maximum allowed length defined by different syslog implementations. Each messsage will include a message identifier as well as a total number of segments and the current segment number, (*1)

The section below shows an example of the format. The identifier here would be 56290be46d:1:2 and 56290be46d:2:2, (*2)

  Oct 22 09:16:36 computer.local laravel[34348]: test.DEBUG: 56290be46d:1:2 Debug log with a lot of [] []
  Oct 22 09:16:36 computer.local laravel[34348]: test.DEBUG: 56290be46d:2:2 text to display [] []

Requirements

Segmented Syslog is tested on Laravel version 4.2 and will work on any PHP system >= 5.3, (*3)

Setup

  1. Install segmented syslog, (*4)

    composer require camuthig/laravel-segmentedsyslog:dev-master
    
  2. Replace the standard LogServiceProvider for SegmentedSyslogServiceProvider in config/app.php. Don't worry, the provider extends the base Laravel provider, so all functionality is still available., (*5)

    'providers' => array(
    ...
    // 'Illuminate\Log\LogServiceProvider',
    'Camuthig\SegmentedSyslog\SegmentedSyslogServiceProvider',
    ...
    ),
    
  3. Update your Log handler in global.php, (*6)

    Log::useSegmentedSyslog();
    

Configuration

When declaring the Log facade to use the segmented syslog, you are able to configure all of the properties for the syslog, with the parameters as follows, (*7)

php public function useSegmentedSyslog( $name = 'laravel', $level = 'debug', $length = 1024, $facility = LOG_USER, $bubble = true, $logopts = LOG_PID ), (*8)

The Versions

23/10 2015

dev-feature/laravel51-support

dev-feature/laravel51-support

A Laravel Syslog Handler to handle maximum message lengths enforced by certain syslog implementations.

  Sources   Download

The Requires

 

The Development Requires

by Chris Muthig

23/10 2015

dev-master

9999999-dev

A Laravel Syslog Handler to handle maximum message lengths enforced by certain syslog implementations.

  Sources   Download

The Requires

 

The Development Requires

by Chris Muthig

23/10 2015

dev-develop

dev-develop

A Laravel Syslog Handler to handle maximum message lengths enforced by certain syslog implementations.

  Sources   Download

The Requires

 

The Development Requires

by Chris Muthig

23/10 2015

1.0.0

1.0.0.0

A Laravel Syslog Handler to handle maximum message lengths enforced by certain syslog implementations.

  Sources   Download

The Requires

 

The Development Requires

by Chris Muthig