Skip to content

[YUNIKORN-1107] Make health check occur in the background#395

Merged
HuangTing-Yao merged 9 commits into
apache:masterfrom
lowc1012:YUNIKORN-1107
Mar 31, 2022
Merged

[YUNIKORN-1107] Make health check occur in the background#395
HuangTing-Yao merged 9 commits into
apache:masterfrom
lowc1012:YUNIKORN-1107

Conversation

@lowc1012
Copy link
Copy Markdown
Contributor

@lowc1012 lowc1012 commented Mar 25, 2022

What is this PR for?

  • Change "ws/v1/scheduler/healthcheck" API to fetch health check cache in scheduler context
  • Run health check periodically in the background

What type of PR is it?

  • - Bug Fix
  • - Improvement
  • - Feature
  • - Documentation
  • - Hot Fix
  • - Refactoring

Todos

  • - Task

What is the Jira issue?

YUNIKORN-1107

How should this be tested?

Screenshots (if appropriate)

Questions:

  • - The licenses files need update.
  • - There is breaking changes for older versions.
  • - It needs documentation.

Comment thread pkg/scheduler/health_checker.go Outdated
Comment thread pkg/scheduler/context.go Outdated
Comment thread pkg/scheduler/context.go Outdated
@lowc1012
Copy link
Copy Markdown
Contributor Author

@pbacsko Thanks for your review!
The above problems have been solved.

Comment thread pkg/webservice/handlers.go Outdated
@HuangTing-Yao
Copy link
Copy Markdown
Contributor

The codecov check doesn't triggered, also we can add TestHealthCheckerStartStop() for start() and stop() to make sure the panic won't happened.

@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 31, 2022

Codecov Report

Merging #395 (acfdd01) into master (affcb27) will increase coverage by 0.06%.
The diff coverage is 70.83%.

@@            Coverage Diff             @@
##           master     #395      +/-   ##
==========================================
+ Coverage   69.54%   69.61%   +0.06%     
==========================================
  Files          67       67              
  Lines        9528     9592      +64     
==========================================
+ Hits         6626     6677      +51     
- Misses       2657     2670      +13     
  Partials      245      245              
Impacted Files Coverage Δ
pkg/common/configs/config.go 76.66% <ø> (ø)
pkg/common/configs/configvalidator.go 86.97% <ø> (ø)
pkg/common/configs/configwatcher.go 85.71% <ø> (ø)
pkg/common/resources/resources.go 97.68% <ø> (ø)
pkg/common/security/acl.go 84.14% <ø> (ø)
pkg/common/security/usergroup.go 85.71% <ø> (ø)
pkg/common/server.go 0.00% <ø> (ø)
pkg/common/utils.go 71.01% <ø> (ø)
pkg/events/event_cache.go 93.18% <ø> (ø)
pkg/events/event_publisher.go 100.00% <ø> (ø)
... and 43 more

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 73d5528...acfdd01. Read the comment docs.

Copy link
Copy Markdown
Contributor

@HuangTing-Yao HuangTing-Yao left a comment

Choose a reason for hiding this comment

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

LGTM

@HuangTing-Yao HuangTing-Yao merged commit 503bc1f into apache:master Mar 31, 2022
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