Improve DnsSrvLookupFailedEvent logging

Description

Suggested release note text:

When a DNS SRV lookup fails due to a missing SRV record, the SDK used to log a scary warning with a stack trace. The lookup failure is typically harmless, so the log message was downgraded to INFO level without a stack trace.

The SDK logs a scary warning when a DNS SRV lookup fails, even though it's typically harmless.

DnsSrv.loadDnsRecords was throwing NullPointerException when no record is found, which caused the event to be logged at WARN level, including a stack trace.

The lookup failure is usually harmless, since the SDK falls back to doing a normal DNS lookup.

It looks like the expected behavior is for it to throw a NameNotFoundException, which causes the event to get logged at INFO level with NO stack trace.

Environment

None

Gerrit Reviews

None

Release Notes Description

None

Activity

Show:
Fixed
Pinned fields
Click on the next to a field label to start pinning.

Details

Assignee

Reporter

Story Points

Sprint

Fix versions

Priority

Instabug

Open Instabug

PagerDuty

Sentry

Zendesk Support

Created June 1, 2022 at 8:20 PM
Updated June 1, 2022 at 11:31 PM
Resolved June 1, 2022 at 11:25 PM
Instabug