thephpleague / tactician-logger

Adds PSR-3 logging support to the Tactician Command Bus
62 stars 8 forks source link

Use log context to inject properties from Command #5

Closed tyx closed 8 years ago

tyx commented 8 years ago

will fix #4

tyx commented 8 years ago

I guess we could also consider to use Symfony\Component\Serializer\Normalizer\GetSetMethodNormalizer as command should have getters or even Symfony\Component\Serializer\Normalizer\PropertyNormalizer

rosstuck commented 8 years ago

At a glance, looks good! Will give it a more thorough read later today/tomorrow when I have more time :)

Symfony Serializer would be great, as long as it's an optional dependency

tyx commented 8 years ago

Other valuable change would be to move class exception and message exception into the context also.

All messages would be on the same schema Command {status}: {ClassName}. Exploitation of these logs would be easier.

rosstuck commented 8 years ago

Read stuff over, talked about this with @boekkooi. Made a couple comments above but overall, looks really good, thanks for picking this up so fast!

I like it and adding the exception info, perhaps the command FQCN as well?

tyx commented 8 years ago

Here are the updated changes and support for FQCN and exception details into context.

tyx commented 8 years ago

Update with renaming

rosstuck commented 8 years ago

Awesome, thanks for all your work on this :)