spring-projects / spring-projects/spring-boot

Allow health indicators to be run asynchronously with the health endpoint providing a view of their current state

Open
#25,459 13 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status: pending-design-work type: enhancement
Dominant language
Java
Stars
81.5k
Forks
42.7k
Avg merge
2d 4h
Merged PRs (30d)
65

Description

Hello,

it would be great that spring boot actuator provides a locking/semaphore/mutex logic out-of-the box to prevent its endpoints from flooding.
I have the "actuator/health" especially in mind, as this endpoint is extendable by custom HealthIndicators with potential problems. One of my HealthIndicators caused a long running task by invocing another service/repository (in the end: a missing response/connection timeout fixed the trouble to some degree). As the calculation took so long, my monitoring system (consul) fired more requests in order to get a state. But that only flooded my system...

Currently, there is a cache logic implemented for the actuator endpoints: once the value is calculated it will be cached. The missing piece for me is the semaphor/lock mechanism for not yet calculated (or obsolete/invalidated) values of actuator endpoints. This feature would help to avoid a flooding of the system.

I was wondering if such a feature could be provided by SpringBoot Actuator (like the caching...) and wanted to reach you out before implementing a custom solution on my own...

Best regards.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing Spring Boot Actuator's health endpoint and its existing caching logic. Done means health indicators can run asynchronously while the endpoint exposes their current state and prevents repeated requests from flooding the system.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring-boot
Domain
backend, observability
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.