Skip to content

Logging message line by line should be done in logger #664

@evaisse

Description

@evaisse

Hi,

The way logging is done is real problem for us now, we do not log message as string but as JSON.

I can override SimpleSAML_Logger but still the way the logger is used is pretty weird, I think about this particular line.

        $str = self::formatXMLString($message);
        foreach (explode("\n", $str) as $line) {
            Logger::debug($line);
        }

https://github.com/simplesamlphp/simplesamlphp/blob/master/lib/SimpleSAML/Utils/XML.php#L130

Maybe splitting log by line should be done IN the logger class instead of application code ?
Because of this, I cannot simply log an entire xml message.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions