Skip to content

Increase character limit for the logger #1827

Closed

Description

@Angelodaniel

A customer gets it's value from the logger but it's been capped at 64 which truncates the information.
Is there a reason for this or can we up the limit to a fair amount like for instance the TagValue => 200

"_meta": { "logger": { "": { "rem": [ [ "!limit", "s", 61, 64 ] ], "len": 86 } } },

can be found in this file

Activity

  1. added
    enhancement
    on Feb 8, 2023
  2. benoit-lateltin commented on Feb 8, 2023

    @benoit-lateltin

    Thank you for considering this.
    In Java, most of the time the logger name is generated from the class name. It can be pretty long because it is a fully qualified name including the package before the actual class name.

    Example: com.company.project.module.layer.subpackage.category.BusinessEntityErrorResolver

    If you have to truncate this value, maybe it would make more sense to keep the class name at the end and truncate the beginning (fully qualified name is always better).

    Should this be implemented in sentry-logback and sentry-log4j because it seems specific to Java logging frameworks?

  3. olksdr commented on Feb 13, 2023

    @olksdr
    Contributor
    • Check the Sentry side if there are any limitation on logger field as well
  4. olksdr commented on Feb 13, 2023

    @olksdr
    Contributor

    @benoit-lateltin it sounds like a good idea.

    Could you, please, also open the issue (feature request) in https://github.com/getsentry/sentry-java ?

  5. iker-barriocanal commented on Mar 14, 2023

    @iker-barriocanal
    Contributor

    After an internal conversation, we'll trim from the beginning of the string instead, keeping the max at 64 unicode chars.

  6. benoit-lateltin commented on Mar 14, 2023

    @benoit-lateltin
  7. iker-barriocanal commented on Mar 14, 2023

    @iker-barriocanal
    Contributor

    @benoit-lateltin no, that won't be necessary. This is something that will happen in relay, no SDK changes are required.

  8. jan-auer commented on Mar 14, 2023

    @jan-auer
    Member

    We can detect class paths during trimming and apply some better trimming logic for these, e.g. trim at . boundaries.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancement

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions