tree: fe7834d8bf2d2fd874d6c21e65ac032ea005b57c [path history] [tgz]
  1. src/
  2. build-ivy.xml
  3. build.xml
  4. howto_upgrade_es.txt
  5. ivy.xml
  6. plugin.xml

indexer-elastic plugin for Nutch

indexer-elastic plugin is used for sending documents from one or more segments to an Elasticsearch server. The configuration for the index writers is on conf/index-writers.xml file, included in the official Nutch distribution and it's as follow:

<writer id="<writer_id>" class="org.apache.nutch.indexwriter.elastic.ElasticIndexWriter">

Each <writer> element has two mandatory attributes:

  • <writer_id> is a unique identification for each configuration. This feature allows Nutch to distinguish each configuration, even when they are for the same index writer. In addition, it allows to have multiple instances for the same index writer, but with different configurations.

  • org.apache.nutch.indexwriter.elastic.ElasticIndexWriter corresponds to the canonical name of the class that implements the IndexWriter extension point. This value should not be modified for the indexer-elastic plugin.


The mapping section is explained here. The structure of this section is general for all index writers.


Each parameter has the form <param name="<name>" value="<value>"/> and the parameters for this index writer are:

Parameter NameDescriptionDefault value
hostComma-separated list of hostnames to send documents to using TransportClient. Either host and port must be defined or cluster.
portThe port to connect to using TransportClient.9300
clusterThe cluster name to discover. Either host and port must be defined or cluster.
indexDefault index to send documents to.nutch
max.bulk.docsMaximum size of the bulk in number of documents.250
max.bulk.sizeMaximum size of the bulk in bytes.2500500
exponential.backoff.millisInitial delay for the BulkProcessor exponential backoff policy.100
exponential.backoff.retriesNumber of times the BulkProcessor exponential backoff policy should retry bulk operations.10
bulk.close.timeoutNumber of seconds allowed for the BulkProcessor to complete its last operation.600