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

[Develop] Backing instance max count updates - _is_node_in_replacement_valid(), is_backing_instance_valid(), and unit tests #622

Merged

Conversation

dreambeyondorange
Copy link
Contributor

@dreambeyondorange dreambeyondorange commented Mar 1, 2024

Description of changes

  • Describe what you're changing and why you're doing these changes.

Tests

  • Ran unit tests locally
  • Created custom clusters to verify EC2 data delay behavior

References

  • Link to impacted open issues.
  • Link to related PRs in other packages (i.e. cookbook, node).
  • Link to documentation useful to understand the changes.

Checklist

  • Make sure you are pointing to the right branch.
  • If you're creating a patch for a branch other than develop add the branch name as prefix in the PR title (e.g. [release-3.6]).
  • Check all commits' messages are clear, describing what and why vs how.
  • Make sure to have added unit tests or integration tests to cover the new/modified code.
  • Check if documentation is impacted by this change.

Please review the guidelines for contributing and Pull Request Instructions.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

…re the instance matches what is being tracked (aws#618)

The missing instance map did not track what the IP address was that was associated with the slurm node.
Because of this if a new instance is launched before an instance becomes healthy, the increment is not reset
for the instance count map.  This change uses a class object to track the data and links the node name to the ip.

Also use the `is_backing_instance_valid()` function in `is_state_healthy()` instead of the plain `node.instance`
object check to allow for the delay in EC2 consistency.
@dreambeyondorange dreambeyondorange requested review from a team as code owners March 1, 2024 02:41
Copy link

codecov bot commented Mar 1, 2024

Codecov Report

Attention: Patch coverage is 94.73684% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 90.78%. Comparing base (293efb7) to head (3714a58).

Files Patch % Lines
src/slurm_plugin/slurm_resources.py 92.85% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #622   +/-   ##
========================================
  Coverage    90.77%   90.78%           
========================================
  Files           20       20           
  Lines         3123     3137   +14     
========================================
+ Hits          2835     2848   +13     
- Misses         288      289    +1     
Flag Coverage Δ
unittests 90.78% <94.73%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

@dreambeyondorange dreambeyondorange merged commit 7bb99a9 into aws:develop Mar 1, 2024
22 of 23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants