kube_pod_status_reason metric add Preempting reason #2595
Labels
kind/feature
Categorizes issue or PR as related to a new feature.
needs-triage
Indicates an issue or PR lacks a `triage/foo` label and requires one.
What would you like to be added:
Add ‘Preempting ’ reason to kube_pod_status_reason
Why is this needed:
We have an alert for pods that are not ready for a long time(Use prometheus-operator by default to have the alert KubePodNotReady ). I want to eliminate some situations, including Evicted and Preempting. However, there is no Preempting in the current reason.
Describe the solution you'd like
kube_pod_status_reason | Gauge | The pod status reasons |
reason=<Evicted|NodeAffinity|NodeLost|Shutdown|UnexpectedAdmissionError>
Add Preempting
The kubernetes code:
![Image](https://private-user-images.githubusercontent.com/23339589/406325276-17a2d0e0-a6ca-4b62-904f-f8c76e4176b7.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNTczODYsIm5iZiI6MTczOTM1NzA4NiwicGF0aCI6Ii8yMzMzOTU4OS80MDYzMjUyNzYtMTdhMmQwZTAtYTZjYS00YjYyLTkwNGYtZjhjNzZlNDE3NmI3LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEyVDEwNDQ0NlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTBkMmFlZjRmZDc0ODAwMGFkOWRlYTMyYTU2ODQ1ODFjMzE0ZTkwYmFkNjY5YmI2NjFkMmZjNzAzMDMwYzYwNjEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.irKD6Ai7UE6qTtL9nF_JJk3R-IdIGSdHG8GP057xGdc)
The text was updated successfully, but these errors were encountered: