@Experimental(value=SOURCE_SINK) public class ElasticsearchIO extends java.lang.Object
ElasticsearchIO.read() returns a bounded PCollection<String> representing JSON documents.
 
To configure the read(), you have to provide a connection configuration
 containing the HTTP address of the instances, an index name and a type. The following example
 illustrates options for configuring the source:
 
 pipeline.apply(ElasticsearchIO.read().withConnectionConfiguration(
    ElasticsearchIO.ConnectionConfiguration.create("http://host:9200", "my-index", "my-type")
 )
 The connection configuration also accepts optional configuration: withUsername(),
 withPassword(), withApiKey() and withBearerToken().
 
You can also specify a query on the read() using withQuery().
 
There are many more configuration options which can be found by looking at the with* methods
 of ElasticsearchIO.Read
 
To write documents to Elasticsearch, use ElasticsearchIO.write(), which writes JSON documents from a PCollection<String> (which can be bounded or unbounded).
 
ElasticsearchIO.Write involves 2 discrete steps:
 
ElasticsearchIO.DocToBulk)
   ElasticsearchIO.BulkIO)
 In most cases, using write() will be desirable. In some cases, one may
 want to use ElasticsearchIO.DocToBulk and ElasticsearchIO.BulkIO directly. Such
 cases might include:
 
docToBulk()
   Note that configurations options for ElasticsearchIO.Write are a union of
 configutation options for ElasticsearchIO.DocToBulk and ElasticsearchIO.BulkIO.
 
To configure ElasticsearchIO.write(), similar to the read, you
 have to provide a connection configuration. For instance:
 
 pipeline
   .apply(...)
   .apply(ElasticsearchIO.write().withConnectionConfiguration(
      ElasticsearchIO.ConnectionConfiguration.create("http://host:9200", "my-index", "my-type")
   )
 There are many more configuration options which can be found by looking at the with* methods
 of ElasticsearchIO.Write
| Modifier and Type | Class and Description | 
|---|---|
| static class  | ElasticsearchIO.BoundedElasticsearchSourceA  BoundedSourcereading from Elasticsearch. | 
| static class  | ElasticsearchIO.BulkIOA  PTransformwriting Bulk API entities created byElasticsearchIO.DocToBulkto
 an Elasticsearch cluster. | 
| static class  | ElasticsearchIO.ConnectionConfigurationA POJO describing a connection configuration to Elasticsearch. | 
| static class  | ElasticsearchIO.DocToBulkA  PTransformconverting docs to their Bulk API counterparts. | 
| static class  | ElasticsearchIO.Document | 
| static class  | ElasticsearchIO.DocumentCoder | 
| static class  | ElasticsearchIO.ReadA  PTransformreading data from Elasticsearch. | 
| static class  | ElasticsearchIO.RetryConfigurationA POJO encapsulating a configuration for retry behavior when issuing requests to ES. | 
| static class  | ElasticsearchIO.WriteA  PTransformwriting data to Elasticsearch. | 
| Modifier and Type | Method and Description | 
|---|---|
| static ElasticsearchIO.BulkIO | bulkIO() | 
| static ElasticsearchIO.DocToBulk | docToBulk() | 
| static ElasticsearchIO.Read | read() | 
| static ElasticsearchIO.Write | write() | 
public static ElasticsearchIO.Read read()
public static ElasticsearchIO.DocToBulk docToBulk()
public static ElasticsearchIO.BulkIO bulkIO()
public static ElasticsearchIO.Write write()