Zend Framework: Zend_Log_Writer_Syslog Component Proposal
| Proposed Component Name | Zend_Log_Writer_Syslog |
|---|---|
| Developer Notes | http://framework.zend.com/wiki/display/ZFDEV/Zend_Log_Writer_Syslog |
| Proposers | Thomas Gelf |
| Zend Liaison | Matthew Weier O'Phinney |
| Revision | 1.0 - 19 September 2008: Posted to mailing list, created proposal after getting some feedback 1.1 - 24 September 2008: Removed Exceptions as PHP doesn't behave as documentation says 1.2 - 27 September 2008: Added "Multi-Instance-Capability" (wiki revision: 20) |
Table of Contents
1. Overview
Zend_Log_Writer_Syslog implements a syslog writer for Zend_Log.
2. References
3. Component Requirements, Constraints, and Acceptance Criteria
4. Dependencies on Other Framework Components
- Zend_Log_Writer_Abstract
5. Theory of Operation
This component implements a syslog writer for Zend_Log.
Syslog benefits:
- There are lots of tools taking care of logfile rotation and such jobs
- You can scale out your application and easily centralize your logs
- Fast, small overhead
6. Milestones / Tasks
- Milestone 1: [DONE] Initial class design
- Milestone 2: [DONE] Create prototype
- Milestone 3: [DONE] Finish proposal and submit for community review
- Milestone 4: Create unit tests
7. Class Index
- Zend_Log_Writer_Syslog
8. Use Cases
| UC-01 |
|---|
| UC-02 |
|---|
11 Comments
comments.show.hideSep 24, 2008
Benjamin Eberlei
Are the error suppressors before syslog and openlog really needed? Because they are expensive PHP-wise. I would like to see a better handling if possible.
Otherwise this is greatly appreciated and needed
Sep 24, 2008
Thomas Gelf
No - so I removed them. After some discussion on ZF's mailing lists, some tests, ptraces and also greps through PHP's source code I discovered that:
So I removed all checks for return values, removed exceptions and dependency on Zend_Log_Exception. Not much code left so far
Sep 28, 2008
Benjamin Eberlei
thats great. this really looks very promising.
Sep 24, 2008
Thomas Gelf
Some thoughts regarding multiple instances of this writer:
Probably most users won't even care about this, one syslog facility and app-name is more than enough - but I would like to do things the right way, so any feedback regarding these thoughts is appreciated!
Cheers,
Thomas
Sep 26, 2008
Thomas Gelf
I extended the proposal as suggested (by myself) - multiple instances are now handled automagically (see UC-04).
Oct 15, 2008
Lars Strojny
Looks good, isn't it ready for review now?
Oct 31, 2008
Matthew Weier O'Phinney
This proposal is accepted for immediate development in the standard incubator.
Mar 18, 2009
Wil Sinclair
Has this proposal been abandoned? Please reply here.
Apr 08, 2009
Thomas Gelf
No, I'm just too lazy for writing tests
I'll try to do so within April - any idea how to test whether a log line made it to syslog or not?
Cheers,
Thomas
Jul 30, 2009
Alexis Metaireau
No news ?
Aug 02, 2009
Thomas Gelf
Matthew finished docs and cleaned up the code - Zend_Log_Writer_Syslog is part of ZF 1.9.0
Cheers,
Thomas