Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

PSR-3 adapter and writer #6

Closed
wants to merge 8 commits into from
Closed

PSR-3 adapter and writer #6

wants to merge 8 commits into from

Conversation

Xerkus
Copy link
Member

@Xerkus Xerkus commented Jul 10, 2015

This PR adds PSR-3 adapter for Zend\Log.
I had to add standalone adapter class as Psr logger interface can not be applied directly to Zend\Log\Logger since some methods are overlapping.

Also new Psr3 writer added to let Zend\Log write to any PSR-3 compatible loggers.

@gianarb
Copy link
Contributor

gianarb commented Jul 10, 2015

I started this feature few time ago! :) Perfect 👍

@weierophinney weierophinney added this to the 2.6.0 milestone Jul 16, 2015
@weierophinney weierophinney self-assigned this Jul 16, 2015
@weierophinney
Copy link
Member

@Xerkus Could you do me a favor?

  • mkdir -p doc/book
  • touch doc/book/psr3.md

and then document both consuming Zend\Log\Logger in a PSR-3 implementation, as well as attaching a PSR-3 implementation as a log writer to Zend\Log\Logger? @GeeH will be porting docs here soon, but this way we have the feature documented once he does, and it's not something we forget later.

BTW, LOVE the PR - very clean, very straight-forward, and a no-brainer.

@Maks3w
Copy link
Member

Maks3w commented Jul 16, 2015

PSR-3 has a compliant test suite Could you add it?

* @coversDefaultClass Zend\Log\Psr3LoggerAdapter
* @covers ::<!public>
*/
class Psr3LoggerAdapterTest extends TestCase
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extend from Psr\Log\Test\LoggerInterfaceTest

@Xerkus
Copy link
Member Author

Xerkus commented Jul 16, 2015

will do
@weierophinney on a side note, this repo does not get irc notifications as it seems.

@Xerkus
Copy link
Member Author

Xerkus commented Jul 18, 2015

Added docs.
I will greatly appreciate if my english will be fixed there.

weierophinney added a commit that referenced this pull request Jul 20, 2015
weierophinney added a commit that referenced this pull request Jul 20, 2015
- Added keys to all test data providers
- Minor formatting updates, primarily to align arrays
weierophinney added a commit that referenced this pull request Jul 20, 2015
weierophinney added a commit that referenced this pull request Jul 20, 2015
@weierophinney
Copy link
Member

Merged to develop for release with 2.6.0

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants