GithubHelp home page GithubHelp logo

elasticsearch-configsync's Introduction

Elasticsearch Config Sync Module Java CI with Maven

Overview

Config Sync Module provides a feature to distribute files, such as script or dictionary file, to nodes in your cluster. These files are managed in .configsync index, and each node sync up with them.

Version

Versions in Maven Repository

Issues/Questions

Please file an issue.

Installation

7.11 -

$ CONFIGSYNC_URL=https://repo.maven.apache.org/maven2/org/codelibs/elasticsearch-configsync/7.11.0/elasticsearch-configsync-7.11.0.zip
$ curl -o /tmp/configsync.zip $CONFIGSYNC_URL
$ mkdir -p /usr/share/elasticsearch/modules/configsync
$ unzip -d /usr/share/elasticsearch/modules/configsync /tmp/configsync.zip

- 7.10

$ $ES_HOME/bin/elasticsearch-plugin install org.codelibs:elasticsearch-configsync:7.10.0

Getting Started

Register File

$ curl -XPOST -H 'Content-Type:application/json' localhost:9200/_configsync/file?path=user-dict.txt --data-binary @user-dict.txt

The above request is to add file info to .configsync index. path parameter is a synced file location under $ES_CONF directory(ex. /etc/elasticsearch/user-dict.txt).

Get File List

Send GET request without path parameter:

$ curl -XGET -H 'Content-Type:application/json' localhost:9200/_configsync/file
{"acknowledged":true,"path":["user-dict.txt"]}

Get File

Send GET request with path parameter:

$ curl -XGET -H 'Content-Type:application/json' localhost:9200/_configsync/file?path=user-dict.txt

Delete File

Send DELETE request with path parameter:

$ curl -XDELETE -H 'Content-Type:application/json' localhost:9200/_configsync/file?path=user-dict.txt

Sync

Each node copies a file from .configsync index periodically if the file is updated. The interval time is specified by configsync.flush_interval in /etc/elasticserch/elasticsearch.yml. The default value is 1m.

configsync.flush_interval: 1m

Reset

To restart a scheduler for checking .configsync index, send POST request as below:

$ curl -XPOST -H 'Content-Type:application/json' localhost:9200/_configsync/reset

elasticsearch-configsync's People

Contributors

marevol avatar deka0106 avatar keiichiw avatar dependabot[bot] avatar

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.