Skip to content

tests: only refresh the minimum sysinfo in mem limit tests.#15702

Merged
alamb merged 1 commit into
apache:mainfrom
ashdnazg:efficient_extended_test
Apr 14, 2025
Merged

tests: only refresh the minimum sysinfo in mem limit tests.#15702
alamb merged 1 commit into
apache:mainfrom
ashdnazg:efficient_extended_test

Conversation

@ashdnazg

Copy link
Copy Markdown
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
Copy Markdown
Contributor Author

Can we run the extended tests on this PR?

@jayzhan211

Copy link
Copy Markdown
Contributor

Run extended tests

@ashdnazg

Copy link
Copy Markdown
Contributor Author

@jayzhan211

Copy link
Copy Markdown
Contributor

it is still running

@ashdnazg

Copy link
Copy Markdown
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
Copy Markdown
Contributor Author

The CI issue is hopefully fixed here: #15704

@2010YOUY01

Copy link
Copy Markdown
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
Copy Markdown
Contributor Author

@jayzhan211 jayzhan211 left a comment

Copy link
Copy Markdown
Contributor

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
@alamb

alamb commented Apr 14, 2025

Copy link
Copy Markdown
Contributor

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