mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2026-03-04 00:01:12 -05:00
Improve debug log #2927
Labels
No labels
P1: Critical
P2: High
P3: Medium
P4: Low
UI
bug
cannot reproduce
compatibility
dependencies
docker
documentation
duplicate
enhancement
enhancement
external libs
feature request
good first issue
help wanted
infrastructure
invalid
localization
needs investigation
performance
potential-duplicate
question
recurrent
research
snap
waiting for data
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/AdGuardHome#2927
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @hoshsadiq on GitHub (Jul 30, 2021).
Problem Description
Debugging issues is really hard. Enabling debug is useless because of the sheer amount and uploading it for AGH team to inspect involves potential privacy issues.
Proposed Solution
It would be great to separate out logging for individual components. Something as simple prefixing log entries with the component name would awesome as that would allow users to grep on specific component so that logs for only those components can be uploaded. This would also aid you in debugging as it allows you to grep on specific components should a user not filter it themselves.
Alternatives Considered
You could go a step further and allow different log levels per component, but this sounds like it might be a little more work.
Additional Information
It looks like you are using your own in-house built logging library so not sure what would be involved to do so, but if you were using an OSS library such as logrus, you could potential use fields or the like.
@ainar-g commented on GitHub (Jul 30, 2021):
We've already been slowly moving logging to a kind of prefixed scheme like you suggest, but the process has been slow and inconsistent. We'll define these a bit better in the future. Ideally, every component should have its own logger, but that is currently hard to do with the logging libraries we're using.