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

Fix #672: Add missing fields in ProbeConfig for configuring Readiness/Liveness Probes #719

Merged
merged 1 commit into from
Jul 5, 2021

Conversation

rohanKanojia
Copy link
Member

@rohanKanojia rohanKanojia commented Jun 11, 2021

Description

Fix #672

  • Add missing fields in ProbeConfig for configuring liveness/readiness
  • Added a check to keep host null in case it matches localhost

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change
  • Chore (non-breaking change which doesn't affect codebase;
    test, version modification, documentation, etc.)

Checklist

@codecov
Copy link

codecov bot commented Jun 11, 2021

Codecov Report

Merging #719 (e1bd82b) into master (2a2c30a) will increase coverage by 0.00%.
The diff coverage is 85.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##             master     #719   +/-   ##
=========================================
  Coverage     46.20%   46.21%           
- Complexity     3241     3246    +5     
=========================================
  Files           413      413           
  Lines         19849    19856    +7     
  Branches       2781     2781           
=========================================
+ Hits           9172     9176    +4     
- Misses         9659     9661    +2     
- Partials       1018     1019    +1     
Impacted Files Coverage Δ
...eclipse/jkube/kit/config/resource/ProbeConfig.java 0.00% <0.00%> (ø)
...clipse/jkube/kit/common/util/KubernetesHelper.java 30.71% <83.33%> (+0.71%) ⬆️
...lipse/jkube/kit/enricher/handler/ProbeHandler.java 98.24% <100.00%> (-0.04%) ⬇️

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 2a2c30a...e1bd82b. Read the comment docs.

@manusa
Copy link
Member

manusa commented Jun 18, 2021

Please rebase, please fix the code smell

@rohanKanojia
Copy link
Member Author

I'm not using IntSupplier for a reason here. It doesn't handle nullable integers well

@manusa
Copy link
Member

manusa commented Jun 18, 2021

I'm not using IntSupplier for a reason here. It doesn't handle nullable integers well

Then remove the warning and provide a hint as to why we use Supplier instead:

    @SuppressWarnings("java:S4276") // IntSupplier throws NullPointerException when unboxing null Integers
    private void setTimeoutInProbeIfNotNull(Probe probe, Supplier<Integer> integerSupplier, BiConsumer<Integer, Probe> probeConsumer) {

@rohanKanojia rohanKanojia force-pushed the pr/issue672 branch 3 times, most recently from f52acff to 311ae7f Compare June 22, 2021 10:16
…ing Readiness/Liveness Probes

Signed-off-by: Rohan Kumar <rohaan@redhat.com>
@sonarcloud
Copy link

sonarcloud bot commented Jul 2, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

89.3% 89.3% Coverage
0.0% 0.0% Duplication

@manusa manusa merged commit acd5106 into eclipse-jkube:master Jul 5, 2021
@manusa manusa added this to the 1.4.0 milestone Jul 5, 2021
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.

Improve our Liveness/Readiness Probe XML configuration support
2 participants