Actuator
21 questions in 7 subtopics.
Endpoints
You add spring-boot-starter-actuator and can reach /actuator/health but /actuator/metrics returns 404. Why, and how do you expose it?Which actuator endpoints would you expose in production, on which port, and which would you never expose publicly? Justify each choice.Define an actuator standard for all services: which endpoints, on which port, with which security, and how monitoring tools discover them.Health indicators and groups
Write a customHealthIndicator that reports DOWN when a downstream pricing service does not answer within 2 seconds, and say how its name appears in /actuator/health.A health endpoint includes checks for the database, Redis, Kafka and three downstream HTTP services. During a downstream outage Kubernetes restarts all pods. What is wrong with this design, and how would you use health groups?Health checks have caused outages in many organisations, for example cascading restarts or traffic removal during dependency failures. What principles would you set for health signals across the company for years to come?Liveness and readiness
What do /actuator/health/liveness and /actuator/health/readiness mean, and how are they enabled?During a long data migration the service should stop receiving traffic but must not be restarted. How do you do this in code with Spring Boot availability states?Define a standard for liveness, readiness and startup probes for all Spring services on Kubernetes.Metrics endpoint
How do you see the 99th percentile latency of GET /orders/{id} through /actuator/metrics, and what must be configured for percentiles?After a deploy, the Prometheus server runs out of memory because one service exports millions of time series. What is the likely cause and fix?Metrics costs for your observability vendor doubled in a year. What standards would you set for metrics in Spring services?Your company spends heavily on several monitoring vendors fed by Micrometer metrics from Spring services. How would you think about vendor choice and exit strategy over many years?Info and build info
How do you show the build version and git commit in /actuator/info?During an incident you need to know which version is running on each of 40 pods. How would you make this quick and reliable?Supply-chain and audit requirements now ask what exact software runs in each service. How would you use actuator info, build info and SBOMs to answer this at company scale?Securing actuator
Write aSecurityFilterChain that allows anyone to call health and info but requires role OPS for every other actuator endpoint.A penetration test downloaded a heap dump from /actuator/heapdump and found database passwords in it. What went wrong and how do you prevent it?Custom endpoints
Write a custom actuator endpoint /actuator/featureflags that lists flags and allows changing one by name.Several teams wrote custom actuator endpoints that change state, such as clearing caches or toggling features, with no audit. How would you govern custom endpoints?Actuator gives every Spring service the same operational surface. What value does this standardisation bring to a large organisation, and where would you deliberately go beyond it?No question matches these choices.