Module org.elasticsearch.xcore
Record Class ModelStoreResponse
java.lang.Object
java.lang.Record
org.elasticsearch.xpack.core.inference.results.ModelStoreResponse
- All Implemented Interfaces:
Writeable
public record ModelStoreResponse(String inferenceId, RestStatus status, Exception failureCause)
extends Record
implements Writeable
Response for storing a model in the model registry using the bulk API.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Constructor Summary
ConstructorsConstructorDescriptionModelStoreResponse(String inferenceId, RestStatus status, Exception failureCause) Creates an instance of aModelStoreResponserecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanIndicates whether some other object is "equal to" this one.booleanfailed()Returns the value of thefailureCauserecord component.inthashCode()Returns a hash code value for this object.Returns the value of theinferenceIdrecord component.status()Returns the value of thestatusrecord component.final StringtoString()Returns a string representation of this record class.voidwriteTo(StreamOutput out)
-
Constructor Details
-
ModelStoreResponse
- Throws:
IOException
-
ModelStoreResponse
Creates an instance of aModelStoreResponserecord class.- Parameters:
inferenceId- the value for theinferenceIdrecord componentstatus- the value for thestatusrecord componentfailureCause- the value for thefailureCauserecord component
-
-
Method Details
-
failed
public boolean failed() -
writeTo
- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
hashCode
public int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. -
inferenceId
Returns the value of theinferenceIdrecord component.- Returns:
- the value of the
inferenceIdrecord component
-
status
Returns the value of thestatusrecord component.- Returns:
- the value of the
statusrecord component
-
failureCause
Returns the value of thefailureCauserecord component.- Returns:
- the value of the
failureCauserecord component
-