org.apache.flume.sink.elasticsearch
Interface ElasticSearchIndexRequestBuilderFactory

All Superinterfaces:
Configurable, ConfigurableComponent
All Known Implementing Classes:
AbstractElasticSearchIndexRequestBuilderFactory, EventSerializerIndexRequestBuilderFactory

public interface ElasticSearchIndexRequestBuilderFactory
extends Configurable, ConfigurableComponent

Interface for creating ElasticSearch IndexRequestBuilder instances from serialized flume events. This is configurable, so any config params required should be taken through this.


Field Summary
static org.apache.commons.lang.time.FastDateFormat df
           
 
Method Summary
 org.elasticsearch.action.index.IndexRequestBuilder createIndexRequest(org.elasticsearch.client.Client client, String indexPrefix, String indexType, Event event)
           
 
Methods inherited from interface org.apache.flume.conf.Configurable
configure
 
Methods inherited from interface org.apache.flume.conf.ConfigurableComponent
configure
 

Field Detail

df

static final org.apache.commons.lang.time.FastDateFormat df
Method Detail

createIndexRequest

org.elasticsearch.action.index.IndexRequestBuilder createIndexRequest(org.elasticsearch.client.Client client,
                                                                      String indexPrefix,
                                                                      String indexType,
                                                                      Event event)
                                                                      throws IOException
Parameters:
client - ElasticSearch Client to prepare index from
indexPrefix - Prefix of index name to use -- as configured on the sink
indexType - Index type to use -- as configured on the sink
event - Flume event to serialize and add to index request
Returns:
prepared ElasticSearch IndexRequestBuilder instance
Throws:
IOException - If an error occurs e.g. during serialization


Copyright © 2009-2013 Apache Software Foundation. All Rights Reserved.