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

✨Comp-backend override resources with selected hardware #4954

Conversation

sanderegg
Copy link
Member

@sanderegg sanderegg commented Oct 30, 2023

What do these changes do?

In billable products, this PR ensures the service resources are set according to the selected EC2 instance type with a safety margin of 1GiB for now as it seems that the dask-sidecar sees a bit less than what is expected.

details

  • ec2_instances client side implementation in service-library
  • director-v2 gets ec2 resources based on pricing unit if available, updates projects_nodes accordingly (NOTE: this should move to the webserver)
  • some cleanup and codeclimate linting

bonus

  • webserver correctly fills projects_nodes table when a project is created from a service

Related issue/s

How to test

DevOps Checklist

@sanderegg sanderegg added the a:director-v2 issue related with the director-v2 service label Oct 30, 2023
@sanderegg sanderegg added this to the Microhistory milestone Oct 30, 2023
@sanderegg sanderegg self-assigned this Oct 30, 2023
@codecov
Copy link

codecov bot commented Oct 30, 2023

Codecov Report

Merging #4954 (f3beec4) into master (04928bd) will increase coverage by 0.0%.
The diff coverage is 82.1%.

Impacted file tree graph

@@           Coverage Diff            @@
##           master   #4954     +/-   ##
========================================
  Coverage    86.8%   86.8%             
========================================
  Files        1210    1056    -154     
  Lines       50256   47076   -3180     
  Branches     1076     891    -185     
========================================
- Hits        43629   40903   -2726     
+ Misses       6390    5975    -415     
+ Partials      237     198     -39     
Flag Coverage Δ
integrationtests 65.1% <76.9%> (+1.4%) ⬆️
unittests 84.8% <79.3%> (+0.2%) ⬆️

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

Files Coverage Δ
...library/src/models_library/rabbitmq_basic_types.py 87.5% <100.0%> (+4.1%) ⬆️
...ervice-library/src/servicelib/rabbitmq/__init__.py 100.0% <ø> (ø)
...ice-library/src/servicelib/rabbitmq/_client_rpc.py 96.8% <100.0%> (ø)
...vice-library/src/servicelib/rabbitmq/_constants.py 100.0% <100.0%> (ø)
...service-library/src/servicelib/rabbitmq/_models.py 89.4% <ø> (-1.9%) ⬇️
...ice-library/src/servicelib/rabbitmq/_rpc_router.py 90.6% <100.0%> (ø)
...src/simcore_service_clusters_keeper/modules/ec2.py 100.0% <ø> (ø)
...e_service_director_v2/api/dependencies/rabbitmq.py 75.0% <100.0%> (+15.0%) ⬆️
...rvice_director_v2/api/routes/computations_tasks.py 90.3% <100.0%> (ø)
...-v2/src/simcore_service_director_v2/core/errors.py 78.0% <100.0%> (ø)
... and 15 more

... and 169 files with indirect coverage changes

Copy link
Contributor

@matusdrobuliak66 matusdrobuliak66 left a comment

Choose a reason for hiding this comment

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

👍

@sanderegg sanderegg force-pushed the service-resources/override-with-ec2-resources branch from cdb9e5d to 80ce87e Compare October 31, 2023 08:29
@sanderegg sanderegg force-pushed the service-resources/override-with-ec2-resources branch from 68979ff to 5438213 Compare October 31, 2023 09:59
@sonarcloud
Copy link

sonarcloud bot commented Oct 31, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@codeclimate
Copy link

codeclimate bot commented Oct 31, 2023

Code Climate has analyzed commit f3beec4 and detected 0 issues on this pull request.

View more on Code Climate.

@sanderegg sanderegg merged commit d8a7094 into ITISFoundation:master Oct 31, 2023
64 checks passed
@sanderegg sanderegg deleted the service-resources/override-with-ec2-resources branch October 31, 2023 11:51
@matusdrobuliak66 matusdrobuliak66 mentioned this pull request Nov 23, 2023
29 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:director-v2 issue related with the director-v2 service
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants