-
Notifications
You must be signed in to change notification settings - Fork 22
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
Logger proxy should be in separate repository #26
Comments
But this is actually the other way around right? It exposes a PSR3 Logger and sends it to Yii. |
Is it useful for more cases than the Symfony mailer? |
Any library that supports logging via PSR could have their logs routed to the yii log dispatcher. |
OK. Do you need a repository? If so, how to name it? |
Any name is fine. Maybe simliar to your |
I cannot fork it because it's empty. Can you give me permissions to write to the repo or create an initial commit so that I can fork and create a PR? |
Created a file. |
Is everything done here? |
Yes, implementing it in this library is now mostly a one-liner, but I have a question. The implementation looks like this: $defaultFactories = Transport::getDefaultFactories(null, null, new Logger(Yii::getLogger())); This would take a reference to the See yiisoft/yii2-psr-log-source#8 for an implementation. If we merge that PR it would be: $defaultFactories = Transport::getDefaultFactories(null, null, new DynamicLogger()); |
This library contains a proxy allowing us to provide a PSR
LoggerInterface
and route its output to Yii's logger.This should be in the core or a separate library, it is a useful tool with and without symfony mailer.
I'm happy to create a PR if you can create a new repo, or to create a PR for the Yii2 core, but I think that's feature frozen. Of course I could make this in my own repository as well but it would be better if it lives in yiisoft.
The text was updated successfully, but these errors were encountered: