Skip to content

refactor: MQ Wave 2 - lock contention, dedup, dead exports#289

Merged
jongio merged 1 commit into
mainfrom
mq/wave2-fixes
May 20, 2026
Merged

refactor: MQ Wave 2 - lock contention, dedup, dead exports#289
jongio merged 1 commit into
mainfrom
mq/wave2-fixes

Conversation

@jongio
Copy link
Copy Markdown
Owner

@jongio jongio commented May 20, 2026

MQ Wave 2 Fixes

Addresses 4 AUTO-FIX findings from Wave 2 (architecture + smells + performance):

  • SM-1 HIGH logbuffer: move file I/O and broadcast outside main mutex - reduces lock contention by holding mu only for the O(1) ring buffer update
  • SM-3 HIGH parallel.go: extract newProjectTask helper - deduplicates task construction across AddNode/Python/DotnetProject
  • SM-5 MEDIUM testing: unexport GenerateTestConfigYAML - only used within package, reduces public API surface
  • SM-6 LOW service_process: use time.NewTimer instead of time.After - timer can be GC'd if process exits early

All tests pass, lint clean, build clean.

…orts

- logbuffer: move file I/O and broadcast outside main mutex (SM-1)
  Reduces lock contention by holding mu only for O(1) ring buffer update
- parallel.go: extract newProjectTask helper (SM-3)
  Deduplicates task construction across AddNode/Python/DotnetProject
- service_process: use time.NewTimer instead of time.After (SM-6)
  Timer can be stopped if process exits early, preventing leak
- testing: unexport GenerateTestConfigYAML (SM-5)
  Only used within package; reduce public API surface

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@jongio jongio merged commit fba4e4a into main May 20, 2026
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.

1 participant