Skip to content

Fix NPE because of thread of DriverScheduler was not closed immediately when stop DN#17616

Merged
JackieTien97 merged 1 commit into
masterfrom
fixStopDN
May 8, 2026
Merged

Fix NPE because of thread of DriverScheduler was not closed immediately when stop DN#17616
JackieTien97 merged 1 commit into
masterfrom
fixStopDN

Conversation

@Wei-hao-Li

@Wei-hao-Li Wei-hao-Li commented May 8, 2026

Copy link
Copy Markdown
Collaborator

Cause:

  1. DriverScheduler.stop() returns before driver threads are fully gone.
  2. During that gap, MPP teardown can deregister FI memory accounting first.
  3. A still-running driver cleanup path then calls MemoryPool.free(...) using the same IDs.
  4. free() hits a removed map entry (null) and throws IllegalArgumentException wrapping NPE.

Signed-off-by: Weihao Li <18110526956@163.com>
@sonarqubecloud

sonarqubecloud Bot commented May 8, 2026

Copy link
Copy Markdown

@JackieTien97
JackieTien97 merged commit efeece6 into master May 8, 2026
18 checks passed
@JackieTien97
JackieTien97 deleted the fixStopDN branch May 8, 2026 02:17
@codecov

codecov Bot commented May 8, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 40.12%. Comparing base (cee5fbb) to head (cbd90d7).
⚠️ Report is 7 commits behind head on master.

Files with missing lines Patch % Lines
...ueryengine/execution/schedule/DriverScheduler.java 0.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master   #17616      +/-   ##
============================================
+ Coverage     40.09%   40.12%   +0.02%     
  Complexity     2554     2554              
============================================
  Files          5177     5177              
  Lines        348659   348758      +99     
  Branches      44591    44609      +18     
============================================
+ Hits         139794   139932     +138     
+ Misses       208865   208826      -39     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

2 participants