|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.elasticsearch.action.bulk.BulkRequest
public class BulkRequest
A bulk request holds an ordered IndexRequest
s and DeleteRequest
s and allows to executes
it in a single batch.
Client.bulk(BulkRequest)
Constructor Summary | |
---|---|
BulkRequest()
|
Method Summary | |
---|---|
BulkRequest |
add(byte[] data,
int from,
int length,
boolean contentUnsafe)
Adds a framed data in binary format |
BulkRequest |
add(DeleteRequest request)
Adds an DeleteRequest to the list of actions to execute. |
BulkRequest |
add(IndexRequest request)
Adds an IndexRequest to the list of actions to execute. |
boolean |
listenerThreaded()
Should the response listener be executed on a thread or not. |
BulkRequest |
listenerThreaded(boolean listenerThreaded)
Sets if the response listener be executed on a thread or not. |
int |
numberOfActions()
|
void |
readFrom(StreamInput in)
|
ActionRequestValidationException |
validate()
|
void |
writeTo(StreamOutput out)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BulkRequest()
Method Detail |
---|
public BulkRequest add(IndexRequest request)
IndexRequest
to the list of actions to execute. Follows the same behavior of IndexRequest
(for example, if no id is provided, one will be generated, or usage of the create flag).
public BulkRequest add(DeleteRequest request)
DeleteRequest
to the list of actions to execute.
public BulkRequest add(byte[] data, int from, int length, boolean contentUnsafe) throws java.lang.Exception
java.lang.Exception
public int numberOfActions()
public ActionRequestValidationException validate()
validate
in interface ActionRequest
public boolean listenerThreaded()
ActionRequest
When not executing on a thread, it will either be executed on the calling thread, or on an expensive, IO based, thread.
listenerThreaded
in interface ActionRequest
public BulkRequest listenerThreaded(boolean listenerThreaded)
ActionRequest
listenerThreaded
in interface ActionRequest
public void readFrom(StreamInput in) throws java.io.IOException
readFrom
in interface Streamable
java.io.IOException
public void writeTo(StreamOutput out) throws java.io.IOException
writeTo
in interface Streamable
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |