Skip to content

Add support for pprof mutex/blocking - #4979

Merged
javiermolinar merged 6 commits into
mainfrom
add_mutex_profiling
Apr 11, 2025
Merged

Add support for pprof mutex/blocking#4979
javiermolinar merged 6 commits into
mainfrom
add_mutex_profiling

Conversation

@mattdurham

@mattdurham mattdurham commented Apr 9, 2025

Copy link
Copy Markdown
Contributor

What this PR does:

This adds default value for blocking and mutex contention. They are very low defaults to have minimal impact on cpu. In practice alloy has been running these same defaults for years. There is no documentation, I will add that in a separate PR since it will be a larger new section on starting tempo.

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]
Comment thread cmd/tempo/main.go Outdated
Comment thread cmd/tempo/main.go Outdated
@mattdurham mattdurham changed the title WIP; Add support for pprof mutex/blocking Apr 11, 2025
Comment thread cmd/tempo/main.go Outdated
printVersion := flag.Bool("version", false, "Print this builds version information")
ballastMBs := flag.Int("mem-ballast-size-mbs", 0, "Size of memory ballast to allocate in MBs.")
mutexProfileFraction := flag.Int("mutex-profile-fraction", 0, "Enable mutex profiling.")
blockProfileThreshold := flag.Int("block-profile-threshold", 0, "Enable block profiling.")

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should change this description.

@javiermolinar javiermolinar left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM , the changelog is not quite right though

@javiermolinar
javiermolinar merged commit 0204ab9 into main Apr 11, 2025
@javiermolinar
javiermolinar deleted the add_mutex_profiling branch April 11, 2025 13:51
mattdurham added a commit to mattdurham/tempo that referenced this pull request Jun 18, 2026
* Add support for pprof mutex/blocking

* Remove environment variables

* Remove no longer needed comment

* Change changelog.md

* Change naming

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

Labels

None yet

3 participants