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

Start instance monitoring before instance is launched #252

Merged
merged 3 commits into from
Feb 3, 2025

Conversation

mlohvynenko
Copy link
Member

@mlohvynenko mlohvynenko commented Jan 31, 2025

ResourceMonitor::ProcessMonitoring() runs on a separate thread and operates with a delay defined by the "poll period" configuration variable.

As a result, ProcessMonitoring() may execute at a moment when instance monitoring has started, but the instance itself has not yet been launched, leading to the following error: main aos_servicemanager[1659]: (monitoring) Failed to get instance monitoring data: not found (resourceusageprovider.cpp:324)

Copy link

codecov bot commented Jan 31, 2025

Codecov Report

Attention: Patch coverage is 21.05263% with 15 lines in your changes missing coverage. Please review.

Project coverage is 84.49%. Comparing base (d615de5) to head (8056108).
Report is 396 commits behind head on develop.

Files with missing lines Patch % Lines
src/common/monitoring/resourcemonitor.cpp 7.14% 13 Missing ⚠️
src/sm/launcher/instance.cpp 50.00% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #252      +/-   ##
===========================================
- Coverage    86.56%   84.49%   -2.07%     
===========================================
  Files           85      155      +70     
  Lines         7448    13540    +6092     
  Branches         0     1675    +1675     
===========================================
+ Hits          6447    11441    +4994     
- Misses        1001     2099    +1098     

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

@mlohvynenko mlohvynenko force-pushed the feature_early_start_monitoring branch from ec4530d to d6f2278 Compare January 31, 2025 16:46
@mlohvynenko mlohvynenko changed the title Feature early start monitoring Start instance monitoring before instance lauch Jan 31, 2025
@mlohvynenko mlohvynenko changed the title Start instance monitoring before instance lauch Start instance monitoring before instance is launched Jan 31, 2025
src/sm/launcher/instance.cpp Outdated Show resolved Hide resolved
src/common/monitoring/resourcemonitor.cpp Show resolved Hide resolved
@mlohvynenko mlohvynenko force-pushed the feature_early_start_monitoring branch from 1cb503e to 2afe68a Compare January 31, 2025 17:43
@mlohvynenko mlohvynenko force-pushed the feature_early_start_monitoring branch 3 times, most recently from c62f54c to e6b8059 Compare February 3, 2025 10:13
@mlohvynenko mlohvynenko force-pushed the feature_early_start_monitoring branch from e6b8059 to 8056108 Compare February 3, 2025 10:16
Copy link

sonarqubecloud bot commented Feb 3, 2025

@al1img al1img merged commit 7bcc8f0 into aosedge:develop Feb 3, 2025
4 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants