Skip to content

This component is the way to integrate ratchet.io service with your Yii app.

Notifications You must be signed in to change notification settings

yiiext/ratchetio-component

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Ratchetio

Ratchetio Component is the way to integrate ratchet.io service with your Yii application. Ratchet.io aggregates and analyzes your application errors and deploys.

Installation

  1. Download ratchetio.php and put it in the same directory where RatchetioComponent.php and RatchetioErrorHandler.php are. For example, protected/extensions/yiiext/components/RatchetioComponent.

  2. Add ratchetio component to the main.php config:

    // ...
    'components' => array(
        // ...
        'ratchetio'=>array(
            'class' => 'ext.yiiext.components.RatchetioComponent', // adjust path if needed
            'accessToken' => 'your_serverside_ratchetio_token',
        ),
    ),
  3. Adjust main.php config to preload the component:

    'preload'=>array('log', 'ratchetio'),
  4. Set RatchetioErrorHandler as error handler:

    'components' => array(
        // ...
        'errorHandler'=>array(
            'class'=>'ext.yiiext.components.ratchetio.RatchetioErrorHandler',
            // ...
        ),
    ),

    You can also pass some additional ratchet.io options in the component config: environment, branch, maxErrno, baseApiUrl etc.

    A good idea is to specify environment as:

    'environment' => isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : 'cli_'.php_uname("n"),

    You can specify alias of your project root directory for linking stack traces ('application' by default):

    'rootAlias' => 'root',

About

This component is the way to integrate ratchet.io service with your Yii app.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages