Class DiskSpaceIndicatorConfiguration
java.lang.Object
io.micronaut.management.health.indicator.diskspace.DiskSpaceIndicatorConfiguration
- All Implemented Interfaces:
Toggleable
@ConfigurationProperties("endpoints.health.disk-space")
public class DiskSpaceIndicatorConfiguration
extends Object
implements Toggleable
Specific configuration properties for the disk space health indicator.
- Since:
- 1.0
- Author:
- James Kleeh
-
Field Summary
Modifier and TypeFieldDescriptionstatic final boolean
The default enable value.static final String
The default path value.static final long
The default threshold value. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetPath()
long
boolean
protected void
setEnabled
(boolean enabled) Default value (true).protected void
Default value (".").protected void
setThreshold
(long threshold) Default value (10485760L => 10MB).
-
Field Details
-
DEFAULT_ENABLED
public static final boolean DEFAULT_ENABLEDThe default enable value.- See Also:
-
DEFAULT_PATH
The default path value.- See Also:
-
DEFAULT_THRESHOLD
public static final long DEFAULT_THRESHOLDThe default threshold value.- See Also:
-
-
Constructor Details
-
DiskSpaceIndicatorConfiguration
public DiskSpaceIndicatorConfiguration()
-
-
Method Details
-
isEnabled
public boolean isEnabled()- Specified by:
isEnabled
in interfaceToggleable
- Returns:
- Whether the health indicator is enabled
-
setEnabled
protected void setEnabled(boolean enabled) Default value (true).- Parameters:
enabled
- Enable the health indication endpoint
-
getPath
- Returns:
- The file path to monitor for disk space
-
setPath
Default value (".").- Parameters:
path
- The file path
-
getThreshold
public long getThreshold()- Returns:
- The threshold
-
setThreshold
Default value (10485760L => 10MB).- Parameters:
threshold
- Set the threshold
-