monolog:
    channels: ['deprecation', 'export', 'import', 'updateImage', 'updateStock', 'updatePrice', 'update', 'notFound']
    handlers:
        export:
            type: rotating_file
            path: "%kernel.logs_dir%/export.log"
#            level: debug
            channels: [ "export" ]
            max_files: 10
            filename_format: "{filename}-{date}"
            date_format: "Y-m-d"
        import:
            type: rotating_file
            path: "%kernel.logs_dir%/import.log"
#            level: debug
            channels: [ "import" ]
            max_files: 10
            filename_format: "{filename}-{date}"
            date_format: "Y-m-d"
        updateImage:
            type: rotating_file
            path: "%kernel.logs_dir%/updateImage.log"
#            level: debug
            channels: [ "updateImage" ]
            max_files: 10
            filename_format: "{filename}-{date}"
            date_format: "Y-m-d"
        updateStock:
            type: rotating_file
            path: "%kernel.logs_dir%/updateStock.log"
#            level: debug
            channels: [ "updateStock" ]
            max_files: 10
            filename_format: "{filename}-{date}"
            date_format: "Y-m-d"
        updatePrice:
            type: rotating_file
            path: "%kernel.logs_dir%/updatePrice.log"
#            level: debug
            channels: [ "updatePrice" ]
            max_files: 10
            filename_format: "{filename}-{date}"
            date_format: "Y-m-d"
        update:
            type: rotating_file
            path: "%kernel.logs_dir%/update.log"
#            level: debug
            channels: [ "update" ]
            max_files: 10
            filename_format: "{filename}-{date}"
            date_format: "Y-m-d"
        notFound:
            type: rotating_file
            path: "%kernel.logs_dir%/notFound.log"
            #            level: debug
            channels: [ "notFound"]
            max_files: 10
            filename_format: "{filename}-{date}"
            date_format: "Y-m-d"

when@dev:
    monolog:
        handlers:
            main:
                type: stream
                path: "%kernel.logs_dir%/%kernel.environment%.log"
                level: debug
                channels: ["!event"]
            # uncomment to get logging in your browser
            # you may have to allow bigger header sizes in your Web server configuration
            #firephp:
            #    type: firephp
            #    level: info
            #chromephp:
            #    type: chromephp
            #    level: info
            console:
                type: console
                process_psr_3_messages: false
                channels: ["!event", "!doctrine", "!console", "!export", "!import", "!update", "!updateImage", "!updateStock", "!notFound", "!updatePrice"]


when@test:
    monolog:
        handlers:
            main:
                type: fingers_crossed
                action_level: error
                handler: nested
                excluded_http_codes: [404, 405]
                channels: ["!event"]
            nested:
                type: stream
                path: "%kernel.logs_dir%/%kernel.environment%.log"
                level: debug

when@prod:
    monolog:
        handlers:
            main:
                type: fingers_crossed
                action_level: error
                handler: nested
                excluded_http_codes: [404, 405]
                buffer_size: 50 # How many messages should be saved? Prevent memory leaks
            nested:
                type: stream
                path: php://stderr
                level: debug
                formatter: monolog.formatter.json
            console:
                type: console
                process_psr_3_messages: false
                channels: ["!event", "!doctrine", "!console", "!export", "!import", "!update", "!updateImage", "!updateStock", "!updatePrice", "!notFound"]
            deprecation:
                type: stream
                channels: [deprecation]
                path: php://stderr
                formatter: monolog.formatter.json
            export:
                type: rotating_file
                path: "%kernel.logs_dir%/export.log"
#                level: debug
                channels: [ "export" ]
                max_files: 10
                filename_format: "{filename}-{date}"
                date_format: "Y-m-d"
            import:
                type: rotating_file
                path: "%kernel.logs_dir%/import.log"
#                level: debug
                channels: [ "import" ]
                max_files: 10
                filename_format: "{filename}-{date}"
                date_format: "Y-m-d"
            updateImage:
                type: rotating_file
                path: "%kernel.logs_dir%/updateImage.log"
#                level: debug
                channels: [ "updateImage" ]
                max_files: 10
                filename_format: "{filename}-{date}"
                date_format: "Y-m-d"
            updateStock:
                type: rotating_file
                path: "%kernel.logs_dir%/updateStock.log"
#                level: debug
                channels: [ "updateStock" ]
                max_files: 10
                filename_format: "{filename}-{date}"
                date_format: "Y-m-d"
            updatePrice:
                type: rotating_file
                path: "%kernel.logs_dir%/updatePrice.log"
#                level: debug
                channels: [ "updatePrice" ]
                max_files: 10
                filename_format: "{filename}-{date}"
                date_format: "Y-m-d"
            update:
                type: rotating_file
                path: "%kernel.logs_dir%/update.log"
#                level: debug
                channels: [ "update" ]
                max_files: 10
                filename_format: "{filename}-{date}"
                date_format: "Y-m-d"
            notFound:
                type: rotating_file
                path: "%kernel.logs_dir%/notFound.log"
                #            level: debug
                channels: [ "notFound"]
                max_files: 10
                filename_format: "{filename}-{date}"
                date_format: "Y-m-d"