Logging full stack trace with Monolog

Actually since version 1.12.0 it is possible to include stacktrace at your log file: there is new method of LineFormatter called includeStacktraces. To use this, you need to overwrite default behaviour of monolog formatter: config.yml monolog: handlers: main: formatter: your.monolog.service.id (rest of config is as usual) services.yml services: your.monolog.service.id: class: Monolog\Formatter\LineFormatter calls: – [includeStacktraces] Check … Read more

How to write logs from one service into separate file?

The MonologBundle logs everything using the same handlers for the whole framework. That means if one of your services needs to log to different handlers, you should create your own Logger/Handler and inject that in your service. This could be an example config (in yaml): services: my_logger: class: Symfony\Bridge\Monolog\Logger arguments: [soap] calls: – [pushHandler, [@my_handler]] … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)