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

[YUNIKORN-1723] Remove string comparison from hasReadyCondition() function #586

Closed
wants to merge 1 commit into from

Conversation

pbacsko
Copy link
Contributor

@pbacsko pbacsko commented May 5, 2023

What is this PR for?

Remove the comparison NodeStatus.String() against nil. It's unnecessary and expensive.

What type of PR is it?

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

Todos

  • - Task

What is the Jira issue?

https://issues.apache.org/jira/browse/YUNIKORN-1723

How should this be tested?

Screenshots (if appropriate)

Questions:

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

@pbacsko pbacsko self-assigned this May 5, 2023
Copy link
Contributor

@zhuqi-lucas zhuqi-lucas left a comment

Choose a reason for hiding this comment

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

Good catch, LGTM +1

@codecov
Copy link

codecov bot commented May 5, 2023

Codecov Report

Merging #586 (ac4ed5e) into master (523b6f0) will increase coverage by 0.02%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #586      +/-   ##
==========================================
+ Coverage   69.97%   69.99%   +0.02%     
==========================================
  Files          47       47              
  Lines        7943     7943              
==========================================
+ Hits         5558     5560       +2     
+ Misses       2177     2175       -2     
  Partials      208      208              
Impacted Files Coverage Δ
pkg/cache/nodes.go 81.81% <100.00%> (ø)

... and 1 file with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@pbacsko pbacsko requested a review from yangwwei May 6, 2023 01:14
Copy link
Contributor

@wilfred-s wilfred-s left a comment

Choose a reason for hiding this comment

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

LGTM
@manirajv06 please check

@manirajv06
Copy link
Contributor

looks good.

@pbacsko pbacsko closed this in 89ba5be May 8, 2023
@pbacsko pbacsko deleted the YUNIKORN-1723 branch April 28, 2024 11:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants