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

Monitor thread errors #1770

Merged
merged 2 commits into from
Feb 3, 2020
Merged

Conversation

narrieta
Copy link
Member

@narrieta narrieta commented Jan 31, 2020

Added code to handle exceptions in the monitor thread main loop.

Minor refactoring of the functions called by the main loop to ensure consistency on how they handle exceptions. I decided to leave log_altered_network_configuration alone for now (it is setup as a high-priority operation).

Tested the refactoring changes using the debugger on a live VM.


This change is Reviewable


if metrics:
for metric in metrics:
report_metric(metric.category, metric.counter, metric.instance, metric.value)
except Exception as e:
logger.warn("Could not poll all the tracked telemetry due to {0}", ustr(e))

self.last_cgroup_polling_telemetry = datetime.datetime.utcnow()
Copy link
Member

Choose a reason for hiding this comment

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

Good catch.

@codecov
Copy link

codecov bot commented Jan 31, 2020

Codecov Report

❗ No coverage uploaded for pull request base (develop@dcf05c0). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##             develop    #1770   +/-   ##
==========================================
  Coverage           ?   68.67%           
==========================================
  Files              ?       82           
  Lines              ?    11737           
  Branches           ?     1645           
==========================================
  Hits               ?     8060           
  Misses             ?     3326           
  Partials           ?      351

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dcf05c0...bb2ecc3. Read the comment docs.

@narrieta narrieta merged commit 8a7058f into Azure:develop Feb 3, 2020
@narrieta narrieta deleted the monitor-thread-errors branch February 3, 2020 17:33
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