lightninglabs / lightninglabs/taproot-assets

[feature]: add goroutine IDs to logs for sections where we use worker pools

Open
#678 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Go
Stars
525
Forks
150
Avg merge
2d 15h
Merged PRs (30d)
31

Description

Is your feature request related to a problem? Please describe.

We use worker pools in a few spots, via fn.ParSlice or other means. The logs do not indicate which goroutine generated which logs, which makes finding the root cause for an issue more difficult.

Describe the solution you'd like

If we generate a unique ID for each goroutine before entering these parallel sections, and add it the logs, that would aid debugging. We could probably reuse the logic for the tapd daemon runtime ID.

Describe alternatives you've considered

Counting log lines manually.

Additional context

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the worker-pool sections that use fn.ParSlice or other parallel mechanisms, then inspect the tapd daemon runtime ID logic for possible reuse. The work is complete when logs from those parallel sections include a unique goroutine ID and the affected logging remains useful for tracing failures.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
observability-sre
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.