Skip to content

enhancement: rework core_uploader/debug images - #1115

Merged
ShelbyZ merged 1 commit into
aws:mainlinefrom
ShelbyZ:core-rework
Apr 22, 2026
Merged

enhancement: rework core_uploader/debug images#1115
ShelbyZ merged 1 commit into
aws:mainlinefrom
ShelbyZ:core-rework

Conversation

@ShelbyZ

@ShelbyZ ShelbyZ commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

Summary

  • rewrite core_uploader as a supervisor for debugging (core, heap, rss)
  • add support for SIGCONT, SIGUSR1 (gcore snapshot), SIGUSR2 (heap snapshot)
  • profile rss during run
  • profile jemalloc heap during run (needs env value setup, see docs)
  • remove redundant EFS images into unified debug
  • rework init-debug to use core_uploader
  • add libunwind (required for gcore snapshot)
  • compile jemalloc profiling support for debug builds
  • add docs (debug/heap-profiling)
  • update docs (valgrind, debugging, READMEs)

Why this change

The current debug image focuses on running and uploading a core file on crash. This is useful unless the application does not crash or no core file is created. The valgrind image uses valgrind for analysis for leaks, but is not useful for debugging memory growth during application lifetime.

This rework aims to enable tracking heap/rss and use the same upload mechanisms to capture on exit and midrun.

Using the jemalloc heaps and rss we can track allocations and discover where memory may be lingering during run. This helps track growth and suggest changes to fluent-bit in the case the memory is not leaked (on exit).

Testing

  • Built AL2/AL2023 debug/init-debug variants
  • Ran each image to check that core files, heap files, and rss files were produced
  • tested EFS wait duration and potential upload

Description for the changelog

enhancement: rework core_uploader/debug images

Licensing

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Comment thread scripts/core_uploader.sh Outdated
Comment thread scripts/core_uploader.sh
- rewrite core_uploader as a supervisor for debugging (core, heap, rss)
- add support for SIGCONT, SIGUSR1 (gcore snapshot), SIGUSR2 (heap
  snapshot)
- profile rss during run
- profile jemalloc heap during run (needs env value setup, see docs)
- remove redundant EFS images into unified debug
- rework init-debug to use core_uploader
- add libunwind (required for gcore snapshot)
- compile jemalloc profiling support for debug builds
- add docs (debug/heap-profiling)
- update docs (valgrind, debugging, READMEs)
@ShelbyZ
ShelbyZ merged commit 87e6107 into aws:mainline Apr 22, 2026
1 check passed
@ShelbyZ
ShelbyZ deleted the core-rework branch April 22, 2026 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants