Skip to end of metadata
Go to start of metadata
You are viewing an old version of this page. View the current version. Compare with Current  |   View Page History

<ac:macro ac:name="unmigrated-inline-wiki-markup"><ac:plain-text-body><![CDATA[

Zend Framework: Zend_Log_Writer_MongoDb Component Proposal

Proposed Component Name Zend_Log_Writer_MongoDb
Developer Notes http://framework.zend.com/wiki/display/ZFDEV/Zend_Log_Writer_MongoDb
Proposers Robert Allen
Zend Liaison TBD
Revision 1.0 - 1 March 2012: Initial Draft. (wiki revision: 3)

Table of Contents

1. Overview

Zend_Log_Writer_MongoDb is a log writer for Zend_Log enabling centralized logging in distributed environments. It enables log aggregation, filtering and prevents the loss of log information in cloud instances that auto-scale down and are not able to copy log files to outside storage. When utilized with 'capped' collections tailing cursors may be implemented for realtime log observations by utilizing the Zend_Tool_Project_Provider_MongoLog project provider.

2. References

3. Component Requirements, Constraints, and Acceptance Criteria

  • This component will require installation of the Mongo extension.
  • This component will require logging collections to be capped for tailing.
  • This component will support mapping of document members via configuration.
  • This component will track origination hostnames as part of the document saved.

4. Dependencies on Other Framework Components

  • MongoDb pecl extension
  • Zend_Log_Writer_Abstract
  • Zend_Tool_Project_Provider_Abstract
  • Zend_Tool_Project_Provider_Exception

5. Theory of Operation

The Zend_Log_Writer_MongoDb component may be instantiated explicitly as a writer and attached to an existing Zend_Log instance, via the Zend_Log_Writer_MongoDb::factory() method, or the Zend_Log::factory().

The Zend_Tool_Project_Provider_MongoLog if elected to be included would examine the project resources for a MongoDb writer type for determination of configuration or throw an Zend_Tool_Project_Provider_Exception. This tool will watch the logs of all servers in the cluster and tail them in realtime. The three options are:

6. Milestones / Tasks

Describe some intermediate state of this component in terms of design notes, additional material added to this page, and / code. Note any significant dependencies here, such as, "Milestone #3 can not be completed until feature Foo has been added to ZF component XYZ." Milestones will be required for acceptance of future proposals. They are not hard, and many times you will only need to think of the first three below.

  • Milestone 1: Complete review and incorporate feedback into design.
  • Milestone 2: Complete Unit tests.
  • Milestone 3: Complete prototypical code and passing all unit tests.
  • Milestone 5: Complete documentation.

7. Class Index

  • Zend_Log_Writer_MongoDb
  • Zend_Tool_Project_Provider_MongoLog

8. Use Cases

UC-01
UC-02
UC-03
UC-04
UC-05

Tailing Cursor Example:

UC-06
UC-07

Example Document

9. Class Skeletons

]]></ac:plain-text-body></ac:macro>

Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.