fix: resolve memory leaks, race conditions, and listener cleanup issues in parallel task execution#74
Open
nikomatt69 wants to merge 1 commit intoxmaxfrom
Open
Conversation
…es in parallel task execution Memory Leak Fixes: - streaming-orchestrator: Remove absorbed messages beyond limit to prevent messageQueue growth - streaming-orchestrator: Add performPostTaskCleanup() to clean state after parallel task completion - agent-service: Add cleanupCompletedTasks() to remove old completed tasks from activeTasks map - plan-executor: Add cleanupExecutionHistory() and clearExecutionHistory() methods - parallel-task-context-manager: Add automatic cleanup of completed chains after 60 seconds - parallel-task-context-manager: Add dispose() method for full resource cleanup Listener Cleanup Fixes: - plan-executor: Refactor executeAgentStep() to use proper listener tracking and guaranteed cleanup in finally block - plan-executor: Clear timeout handles and all registered listeners even on errors or timeouts Race Condition Fixes: - plan-executor: Use local variable tracking for listeners to prevent race between timeout and completion - streaming-orchestrator: Ensure input queue bypass is disabled after task completion Additional Improvements: - Add bounds on Map sizes to prevent unbounded growth - Clear panels content on task completion to free memory - Clean adaptive metrics entries to prevent accumulation
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ❌ Deployment failed View logs |
nikcli | f664186 | Jan 06 2026, 05:36 AM |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Memory Leak Fixes:
Listener Cleanup Fixes:
Race Condition Fixes:
Additional Improvements: