Skip to content

feat: Health handling#70

Merged
thced merged 14 commits into
masterfrom
feat/health-handling
May 20, 2026
Merged

feat: Health handling#70
thced merged 14 commits into
masterfrom
feat/health-handling

Conversation

@thced

@thced thced commented May 20, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@sasjo sasjo left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can simplify and rely on default mapping paths.

* @param outcome overall outcome; {@code "Up"} (case-insensitive) means healthy
* @param dependencies per-dependency statuses; {@code null} is normalised to an empty list
*/
public record HealthOutcome(String outcome, List<Dependency> dependencies) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not boolean outcome and let the "wireshape" translate it to outcome "Up"?

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we "hand roll" a serializer/renderer for health checks instead of relying on the Gson mapper we anyway will fallback to? This renderer means you cannot serve health as anything but application/json.

I don't have any issues with this being quite similar to regular request handlers where it's quite predictable how they'd encode the data.

@sonarqubecloud

Copy link
Copy Markdown

@thced thced merged commit 35ec1be into master May 20, 2026
5 checks passed
@thced thced deleted the feat/health-handling branch May 20, 2026 09:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants