Giter VIP home page Giter VIP logo

elasticsearch-river-sofa's Introduction

Sofa River Plugin for ElasticSearch

The Sofa River plugin allows indexing of many CouchDB databases into an ElasticSearch index.

Motivation

The Sofa river takes a different strategy from the CouchDB river. You specify a regular expression of database names db_filter in the configuration and all documents in matching databases are indexed. This means new databases will be automatically indexed as created without manually creating a new river.

Implementation

The Sofa river polls the CouchDB _all_dbs endpoint and then loops through all the databases. This is not an efficient way to monitor changes. Because of this the river will exponentially back off if no changes are detected. You can use the backoff_min and backoff_max parameters to configure the balance between resource intensivity and index latency.

Installation

In order to install the plugin, simply run: bin/plugin -install adamlofts/elasticsearch-river-sofa/0.0.5.

Configuration

The following will index all CouchDB databases prefixed with test into the my_es_index index with doc type my_es_type.

curl -XPUT 'localhost:9200/_river/river1/_meta' -d '{
    "type" : "sofa",
    "couchdb" : {
        "host" : "localhost",
        "port" : 5984,
        "db_filter" : "test.*"
    },
    "index" : {
        "index" : "index1",
        "type" : "test1",

        "bulk_size": 10,
        "backoff_min" : 1000,
        "backoff_max" : 60000
    }
}'

Development

To build the plugin from source type mvn assembly:assembly.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.