Package org.elasticsearch.action.bulk
Class BulkItemRequest
java.lang.Object
org.elasticsearch.action.bulk.BulkItemRequest
- All Implemented Interfaces:
org.apache.lucene.util.Accountable
,Writeable
public class BulkItemRequest extends java.lang.Object implements Writeable, org.apache.lucene.util.Accountable
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
Field Summary
-
Constructor Summary
Constructors Constructor Description BulkItemRequest(int id, DocWriteRequest<?> request)
-
Method Summary
Modifier and Type Method Description void
abort(java.lang.String index, java.lang.Exception cause)
Abort this request, and store aBulkItemResponse.Failure
response.int
id()
java.lang.String
index()
long
ramBytesUsed()
DocWriteRequest<?>
request()
void
writeThin(StreamOutput out)
void
writeTo(StreamOutput out)
Write this into the StreamOutput.
-
Constructor Details
-
Method Details
-
id
public int id() -
request
-
index
public java.lang.String index() -
abort
public void abort(java.lang.String index, java.lang.Exception cause)Abort this request, and store aBulkItemResponse.Failure
response.- Parameters:
index
- The concrete index that was resolved for this requestcause
- The cause of the rejection (may not be null)- Throws:
java.lang.IllegalStateException
- If a response already exists for this request
-
writeTo
Description copied from interface:Writeable
Write this into the StreamOutput. -
writeThin
- Throws:
java.io.IOException
-
ramBytesUsed
public long ramBytesUsed()- Specified by:
ramBytesUsed
in interfaceorg.apache.lucene.util.Accountable
-