Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added a documentation article for logging #51

Merged
merged 4 commits into from
Dec 21, 2014
Merged

Added a documentation article for logging #51

merged 4 commits into from
Dec 21, 2014

Conversation

mnapoli
Copy link
Contributor

@mnapoli mnapoli commented Dec 15, 2014

References matomo-org/matomo#6813

I've added an article to document:

  • how to use the new PSR-3 logger
  • how plugins can override its configuration

The second part was removed because it has a lot to do with DI config, which is still a moving topic. We do not want to expose that API yet.

If you want to see the removed part: https://github.com/piwik/developer-documentation/blob/f2606256f41ddd85b350d8c4ad2cf93b2c548bf1/docs/logging.md

This PR depends on matomo-org/matomo#6813

@mnapoli
Copy link
Contributor Author

mnapoli commented Dec 15, 2014

After discussions, I've removed the "Logger configuration" section because it has to do with DI configuration, which is not yet stable and we don't want to expose it to 3rd party plugins yet.

If you still want to read it (I think it's a good example of what will be possible in the future): https://github.com/piwik/developer-documentation/blob/f2606256f41ddd85b350d8c4ad2cf93b2c548bf1/docs/logging.md

Conflicts:
	app/helpers/Content/Category/DevelopCategory.php
$logger->debug('This is a debug message');
```

Each of this message will or will not be logged according to the log level configured by the user. Developers should not log conditionally according to the current log level: they should simply log and let the system figure it all out.
Copy link
Member

Choose a reason for hiding this comment

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

each of these

Copy link
Member

Choose a reason for hiding this comment

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

according to the log level configured by the user

according to the log level configured by the user in their config.ini.php ?

@mnapoli
Copy link
Contributor Author

mnapoli commented Dec 21, 2014

Fixed your comments @mattab, merging now.

mnapoli added a commit that referenced this pull request Dec 21, 2014
Added a documentation article for logging
@mnapoli mnapoli merged commit edb05ed into master Dec 21, 2014
@mnapoli mnapoli deleted the logging branch December 21, 2014 21:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants