Skip to content

Conversation

ashdnazg
Copy link
Contributor

Rationale for this change

Currently the memory limit tests hang due to lock contention and the overhead from frequently calling sysinfo::System::refresh_all() in the memory monitoring task.

In fact, we don't really need to refresh all info, it's enough to just get the memory data about the current process, which significantly reduces the refresh time and the tests finish quickly.

What changes are included in this PR?

In the memory limit utils, the memory monitoring spawned task now refreshes system info only for what's actually necessary.

Are these changes tested?

It's part of the tests, and they seem to not hang anymore :)

Are there any user-facing changes?

No

@ashdnazg
Copy link
Contributor Author

Can we run the extended tests on this PR?

@jayzhan211
Copy link
Contributor

Run extended tests

@ashdnazg
Copy link
Contributor Author

@jayzhan211
Copy link
Contributor

it is still running

@ashdnazg
Copy link
Contributor Author

I don't think it does, the spawning crashed, there's nothing running here: https://github.com/apache/datafusion/actions?query=workflow%3A%22Datafusion+extended+tests%22

@ashdnazg
Copy link
Contributor Author

The CI issue is hopefully fixed here: #15704

@2010YOUY01
Copy link
Contributor

Thank you for the fix. To test this PR, I think you can push the change to your cloned repository of datafusion's main branch, and the extended test CI will be triggered there. (Maybe you have to also enable GitHub action first in your cloned repo, I can't remember exactly how)

@ashdnazg
Copy link
Contributor Author

Copy link
Contributor

@jayzhan211 jayzhan211 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏻

@alamb alamb merged commit 0baf1c3 into apache:main Apr 14, 2025
27 of 28 checks passed
@alamb
Copy link
Contributor

alamb commented Apr 14, 2025

Thank you @ashdnazg and @jayzhan211

nirnayroy pushed a commit to nirnayroy/datafusion that referenced this pull request May 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core Core DataFusion crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants