Skip to content

Conversation

@janvanmansum
Copy link
Contributor

Fixes DD-

Description of changes

How to test

Related PRs

(Add links)
*

Notify

@DANS-KNAW/core-systems

@janvanmansum janvanmansum requested a review from Copilot January 28, 2026 15:30
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR implements a new health check class to monitor file system free space against a configurable threshold.

Changes:

  • Added FileSystemFreeSpaceHealthCheck class that extends Dropwizard's HealthCheck to verify sufficient free space on a file system
  • Added comprehensive unit tests with mocked file system interactions to validate both healthy and unhealthy scenarios

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/main/java/nl/knaw/dans/lib/util/healthcheck/FileSystemFreeSpaceHealthCheck.java Implements the health check logic to compare available space against required margin
src/test/java/nl/knaw/dans/lib/util/healthcheck/FileSystemFreeSpaceHealthCheckTest.java Provides test coverage for both success and failure cases using mocked FileStore

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@codecov
Copy link

codecov bot commented Jan 28, 2026

Codecov Report

❌ Patch coverage is 87.50000% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 47.18%. Comparing base (f71d2eb) to head (53f781b).
⚠️ Report is 4 commits behind head on master.

Files with missing lines Patch % Lines
...il/healthcheck/FileSystemFreeSpaceHealthCheck.java 87.50% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master      #30      +/-   ##
============================================
+ Coverage     46.74%   47.18%   +0.44%     
- Complexity       99      101       +2     
============================================
  Files            28       29       +1     
  Lines           721      729       +8     
  Branches         81       82       +1     
============================================
+ Hits            337      344       +7     
- Misses          349      350       +1     
  Partials         35       35              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@janvanmansum janvanmansum merged commit 53f781b into DANS-KNAW:master Jan 29, 2026
6 checks passed
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.

1 participant