Search in sources :

Example 16 with Write

use of org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.Write in project beam by apache.

the class ElasticsearchIOTestCommon method testWrite.

void testWrite() throws Exception {
    Write write = ElasticsearchIO.write().withConnectionConfiguration(connectionConfiguration);
    executeWriteTest(write);
}
Also used : Write(org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.Write)

Example 17 with Write

use of org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.Write in project beam by apache.

the class ElasticsearchIOTestCommon method testWriteStateful.

void testWriteStateful() throws Exception {
    Write write = ElasticsearchIO.write().withConnectionConfiguration(connectionConfiguration).withUseStatefulBatches(true);
    executeWriteTest(write);
}
Also used : Write(org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.Write)

Aggregations

Write (org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.Write)17 Document (org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.Document)6 BulkIO (org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.BulkIO)5 ArrayList (java.util.ArrayList)4 IOException (java.io.IOException)3 PCollectionTuple (org.apache.beam.sdk.values.PCollectionTuple)3 ObjectNode (com.fasterxml.jackson.databind.node.ObjectNode)2 PipedInputStream (java.io.PipedInputStream)2 PipedOutputStream (java.io.PipedOutputStream)2 DocumentCoder (org.apache.beam.sdk.io.elasticsearch.ElasticsearchIO.DocumentCoder)2 Instant (org.joda.time.Instant)2 JsonNode (com.fasterxml.jackson.databind.JsonNode)1 Serializable (java.io.Serializable)1 StandardCharsets (java.nio.charset.StandardCharsets)1 Arrays (java.util.Arrays)1 Collections (java.util.Collections)1 List (java.util.List)1 Map (java.util.Map)1 Set (java.util.Set)1 ThreadLocalRandom (java.util.concurrent.ThreadLocalRandom)1