KubeKleaner (short for Kubernetes Kleaner) is a Java application built on the Spring Boot framework and the AT&T Java Service Container (AJSC).
KubeKleaner utilizes Spring Boot’s scheduled task functionality to leverage the Kubernetes API for deleting failing microservice deployments and their downstream resources based on a configurable expiration time.
The cleanup process is configurable but by default happens once daily. The Kubernetes clusters that KubeKleaner can reach is configured in the application’s properties file.
The cleanup process loops through all pods in the specified cluster(s) and works as follows on each iteration:
The above strategy is implemented in CleanupServiceImpl.java.
As configured by default, KubeKleaner runs once daily at 10:00 A.M. PST.
The expiration date for Kubernetes resources is by default set for one week. This can be made shorter or longer via the “numWeeks” environment variable as found in application.yml.
Upon a successful cleanup by KubeKleaner, a HipChat notification (if configured) will be sent to a chosen HipChat room with the following information tied to the deleted resources:
You can read more about kubecleaner in this blog post.
This chart bootstraps a Prometheus Postgres exporter deployment on a Kubernetes…
An autoscaler that call user-specified webhooks when conditions for scale…
This article describes how to set up and use Azure Monitor container health to…
Tell us about a new Kubernetes application
Never miss a thing! Sign up for our newsletter to stay updated.
Discover and learn about everything Kubernetes