CMQLogRoute Extension ¶
The 'CMQLogRoute' is a Yii Framework Plugin that avoids to write log-messages to MQ-exchange.
Requirements ¶
- Yii 1.1.*
- CAMQP yii-extension (http://www.yiiframework.com/extension/amqp)
Installation ¶
- Unpack all files under your project 'extension' folder
- Set up your log route in main.php configuration file:
'components' => array( ........
...
'log' => array(
'class' => 'CLogRouter',
'routes' => array(
...
array(
'class' => 'application.extensions.MQLogRoute.CMQLogRoute',
'enabled' => true,
'levels' => 'info,error,warning',
'mqID' => 'mq', // The name of component that represents camqp-extension. You can use this extension: http://http://www.yiiframework.com/extension/amqp
'mqExchange' => 'yiilog' // The name of MQ-exchange
),
........
...
),
),
........
)
......
- Enjoy!
.
.
Usage: ¶
Write log by standart Yii's method
Yii::log('Writing to MQ!');
Changelog: ¶
1.0 - Initial release
If you have any questions, please ask in the forum instead.
Signup or Login in order to comment.