Skip to content
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

Reduce acceptance test sled memory usage #1236

Merged
merged 2 commits into from
Nov 9, 2020
Merged

Conversation

teor2345
Copy link
Contributor

@teor2345 teor2345 commented Oct 30, 2020

Motivation

PR #1233 changed the default memory_cache_bytes, but left the
acceptance tests with their old value.

Solution

To avoid similar issues in future, we simply divide the default by 2 just use the default memory limit setting.

Related Issues

Ticket #1026 sled memory usage
PR #1233 default and documentation changes for memory_cache_bytes.

Reviewer

@hdevalence was the author of PR #1233, this PR is a follow-up.
This is a one line change.

This PR is not urgent, unless we are having test memory usage issues.
@dconnolly, you might want to check the memory_cache_bytes setting in the long-running sync tests.

PR #1233 changed the default `memory_cache_bytes`, but left the
acceptance tests with their old value.

To avoid similar issues in future, we simply divide the default by 2.
@teor2345 teor2345 added the A-rust Area: Updates to Rust code label Oct 30, 2020
@teor2345 teor2345 added this to the First Alpha Release milestone Oct 30, 2020
@teor2345 teor2345 requested a review from hdevalence October 30, 2020 08:27
@teor2345 teor2345 self-assigned this Oct 30, 2020
@hdevalence
Copy link
Contributor

Before, we had a reduced memory limit for tests, because the default limit was too large. But now the default is lower. Do we actually want to have the test limit be half of the default limit? Or, could we simply eliminate this setting and use the default, now that we've hopefully fixed the problem that the default limit was too large?

@teor2345
Copy link
Contributor Author

teor2345 commented Nov 2, 2020

Before, we had a reduced memory limit for tests, because the default limit was too large. But now the default is lower. Do we actually want to have the test limit be half of the default limit? Or, could we simply eliminate this setting and use the default, now that we've hopefully fixed the problem that the default limit was too large?

The tests run in parallel, so I initially thought we might need a lower memory limit.

But there are actually 2 different types of tests:

  • tests that only sync 1 or 1200 blocks - they won't have memory usage issues
  • test that sync the whole chain - they need the full memory limit

So I don't think this change is necessary.

@teor2345 teor2345 closed this Nov 2, 2020
@teor2345 teor2345 reopened this Nov 5, 2020
@teor2345 teor2345 added the C-bug Category: This is a bug label Nov 5, 2020
@teor2345
Copy link
Contributor Author

teor2345 commented Nov 5, 2020

@hdevalence I made a mistake here - we actually need to delete the code that increases the memory limit in the tests, so that the tests just use the default memory limit.

Copy link
Contributor

@oxarbitrage oxarbitrage left a comment

Choose a reason for hiding this comment

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

ACK.

@teor2345 teor2345 merged commit efef2a2 into main Nov 9, 2020
@teor2345 teor2345 deleted the acceptance-sled-memory branch November 9, 2020 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-rust Area: Updates to Rust code C-bug Category: This is a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants