Class BulkItemRequest

  • All Implemented Interfaces:
    Streamable

    public class BulkItemRequest
    extends java.lang.Object
    implements Streamable
    • Constructor Detail

      • BulkItemRequest

        public BulkItemRequest​(int id,
                               DocWriteRequest<?> request)
    • Method Detail

      • id

        public int id()
      • index

        public java.lang.String index()
      • abort

        public void abort​(java.lang.String index,
                          java.lang.Exception cause)
        Abort this request, and store a BulkItemResponse.Failure response.
        Parameters:
        index - The concrete index that was resolved for this request
        cause - The cause of the rejection (may not be null)
        Throws:
        java.lang.IllegalStateException - If a response already exists for this request
      • readBulkItem

        public static BulkItemRequest readBulkItem​(StreamInput in)
                                            throws java.io.IOException
        Throws:
        java.io.IOException