Module org.elasticsearch.server
Record Class FileSettingsService.FileSettingsHealthInfo
java.lang.Object
java.lang.Record
org.elasticsearch.reservedstate.service.FileSettingsService.FileSettingsHealthInfo
- All Implemented Interfaces:
Writeable
- Enclosing class:
FileSettingsService
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final FileSettingsService.FileSettingsHealthInfoIndicates that no conclusions can be drawn about the health status.static final FileSettingsService.FileSettingsHealthInfoIndicates that the health info system is active and no changes have occurred yet, so all is well. -
Constructor Summary
ConstructorsConstructorDescriptionFileSettingsHealthInfo(boolean isActive, long changeCount, long failureStreak, String mostRecentFailure) Creates an instance of aFileSettingsHealthInforecord class. -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the value of thechangeCountrecord component.changed()final booleanIndicates whether some other object is "equal to" this one.longReturns the value of thefailureStreakrecord component.final inthashCode()Returns a hash code value for this object.inactive()booleanisActive()Returns the value of theisActiverecord component.Returns the value of themostRecentFailurerecord component.final StringtoString()Returns a string representation of this record class.voidwriteTo(StreamOutput out) Write this into the StreamOutput.
-
Field Details
-
INDETERMINATE
Indicates that no conclusions can be drawn about the health status. -
INITIAL_ACTIVE
Indicates that the health info system is active and no changes have occurred yet, so all is well.
-
-
Constructor Details
-
FileSettingsHealthInfo
- Throws:
IOException
-
FileSettingsHealthInfo
public FileSettingsHealthInfo(boolean isActive, long changeCount, long failureStreak, String mostRecentFailure) Creates an instance of aFileSettingsHealthInforecord class.- Parameters:
isActive- the value for theisActiverecord componentchangeCount- the value for thechangeCountrecord componentfailureStreak- the value for thefailureStreakrecord componentmostRecentFailure- the value for themostRecentFailurerecord component
-
-
Method Details
-
writeTo
Description copied from interface:WriteableWrite this into the StreamOutput.- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
inactive
-
changed
-
successful
-
failed
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
isActive
public boolean isActive()Returns the value of theisActiverecord component.- Returns:
- the value of the
isActiverecord component
-
changeCount
public long changeCount()Returns the value of thechangeCountrecord component.- Returns:
- the value of the
changeCountrecord component
-
failureStreak
public long failureStreak()Returns the value of thefailureStreakrecord component.- Returns:
- the value of the
failureStreakrecord component
-
mostRecentFailure
Returns the value of themostRecentFailurerecord component.- Returns:
- the value of the
mostRecentFailurerecord component
-