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

Add an environment loader API and implementation for some DMI related fields #1063

Merged
merged 19 commits into from
Oct 17, 2023

Conversation

JonathanHenson
Copy link
Contributor

Adds an environment loading API as these probes are not cheap and this is my proposal for keeping it from getting to messy over time.

Long term I see this containing metadata about NIC configurations, cpu and gpu information, memory bus information, etc... Then other parts of the system can load the environment once to make optimization and defaulting decisions.

This is currently being used in aws-c-s3 for determining if we're running on ec2 nitro and figuring out the instance type. It's very much intended to contain more data over time as the configurations get more involved.

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

@JonathanHenson JonathanHenson requested a review from a team October 11, 2023 20:15
@codecov-commenter
Copy link

codecov-commenter commented Oct 11, 2023

Codecov Report

Attention: 12 lines in your changes are missing coverage. Please review.

Comparison is base (0baed28) 82.73% compared to head (93672d5) 82.65%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1063      +/-   ##
==========================================
- Coverage   82.73%   82.65%   -0.09%     
==========================================
  Files          52       54       +2     
  Lines        5664     5707      +43     
==========================================
+ Hits         4686     4717      +31     
- Misses        978      990      +12     
Files Coverage Δ
source/linux/system_info.c 100.00% <100.00%> (ø)
source/system_info.c 66.66% <66.66%> (ø)

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

include/aws/common/system_info.h Show resolved Hide resolved
include/aws/common/system_info.h Show resolved Hide resolved
source/file.c Outdated Show resolved Hide resolved
include/aws/common/private/system_info_priv.h Show resolved Hide resolved
include/aws/common/private/system_info_priv.h Outdated Show resolved Hide resolved
include/aws/common/system_info.h Outdated Show resolved Hide resolved
include/aws/common/system_info.h Outdated Show resolved Hide resolved
source/system_info.c Outdated Show resolved Hide resolved
source/system_info.c Outdated Show resolved Hide resolved
@JonathanHenson JonathanHenson merged commit b61c12e into main Oct 17, 2023
50 of 51 checks passed
@JonathanHenson JonathanHenson deleted the env_detection branch October 17, 2023 20:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants