Skip to content

Remove exception details from logging for info, warn and debug? #2951

@guwirth

Description

@guwirth

In the past we did some refactoring and were removing technical debt saying "Exception handlers should preserve the original exceptions"

https://sonarcloud.io/organizations/sonaropencommunity/rules?open=java%3AS1166&rule_key=java%3AS1166

Sample:

LOG.debug("named-capturing group '{}' is not used in regex.", groupName, e);

Think for LOG.error it's correct to simply add/log e. Wondering if we should change that for LOG.info, LOG.warning and LOG.debug?

Sub-issues

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions