8000 Is it possible to truncate ALL log messages so that they don't exceed a particular length? · Issue #1947 · Seldaek/monolog · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Is it possible to truncate ALL log messages so that they don't exceed a particular length? #1947
Open
@armclosinglock

Description

@armclosinglock

Monolog version 3

Is it possible to truncate all messages to not exceed a length of say 5000, or 10000 characters?

I see that in Monolog version 3, messages are immutable so the following does NOT work.

$record['message'] = substr($record['message'], 0, 5000);

I tried something like

$record->withMessage(substr($record['message'],0, 5000));

as well, but I ran into a strange error running compose install in the pipeline that seems to be related to this change that I don't quite understand.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0