Skip to content

Not possible to pass empty string into DSN under logback #2833

@cowwoc

Description

@cowwoc

Integration

sentry-logback

Java Version

20

Version

6.25.0

Steps to Reproduce

Sentry.java shows an exception throw new IllegalArgumentException("DSN is required. Use empty string to disable SDK.");

However, it is impossible to pass an empty string as the DSN in logback.xml because Logback interprets an empty string value as the property not existing altogether.

The only thing that seems to work is to pass an undefined property as the value because SentryAppender checks if the DSN ends with "IS_UNDEFINED".

Expected Result

Either document a way to pass an empty string into dsn in logback.xml, or update the documentation and exception message to indicate what we are supposed to do under Logback.

Actual Result

N/A

Metadata

Metadata

Assignees

Labels

BugIssue type

Projects

Status

Waiting for: Product Owner

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions