-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-54818][SQL] TaskMemoryManager allocate failed should log errorstack to help check memory usage #53578
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
… stack to help check memory usage
|
gentle ping @cloud-fan @dongjoon-hyun WDYT? |
core/src/main/java/org/apache/spark/memory/TaskMemoryManager.java
Outdated
Show resolved
Hide resolved
| public MemoryBlock allocatePage( | ||
| long size, | ||
| MemoryConsumer consumer, | ||
| boolean isRetry) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add. this avoid print too much stack information.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
given we are touching this place, can we use int retryCount instead of a boolean? And we can also log the retry count.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, how about current code.
core/src/main/java/org/apache/spark/memory/TaskMemoryManager.java
Outdated
Show resolved
Hide resolved
| * @throws TooLargePageException | ||
| */ | ||
| public MemoryBlock allocatePage(long size, MemoryConsumer consumer) { | ||
| public MemoryBlock allocatePage( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can this be private now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
What changes were proposed in this pull request?
These days I am checking cluster's OOM failed APP, I found allocate failed didn't log out the error stack. A little not friendly for user check app.
Such as user set 200M broadcast threshold, but allocate 4G memory
Why are the changes needed?
Help user debug
Does this PR introduce any user-facing change?
User can know allocate what memory failed
How was this patch tested?
Before
After
Was this patch authored or co-authored using generative AI tooling?
No