intelligent-machine-learning / dlrover

DLRover: An Automatic Distributed Deep Learning System
Other
1.27k stars 167 forks source link

Delete pod when list pod already succeeded. #1330

Closed BalaBalaYi closed 5 days ago

BalaBalaYi commented 5 days ago

What changes were proposed in this pull request?

Delete pod if status is 'Succeeded' in positive pod list operation.

Why are the changes needed?

Considering that the majority of opinions in the current Kubernetes community are that the resource usage of completed pods should be taken into account, and since the processes and containers have already exited, 'Succeeded' pods do not need to be retained. Therefore 'Succeeded' pods should be deleted.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

UT.

codecov[bot] commented 5 days ago

Codecov Report

Attention: Patch coverage is 85.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 80.85%. Comparing base (a6153a6) to head (7826483). Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
dlrover/python/tests/test_k8s_watcher.py 81.25% 3 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #1330 +/- ## ========================================== - Coverage 80.86% 80.85% -0.01% ========================================== Files 229 229 Lines 21540 21594 +54 ========================================== + Hits 17418 17460 +42 - Misses 4122 4134 +12 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.